-static void test_ctdb_event_reply_data(void)
-{
- TALLOC_CTX *mem_ctx;
- size_t buflen;
- struct ctdb_event_reply_data rd, rd2;
- uint32_t command;
- int ret;
-
- printf("ctdb_event_reply_data\n");
- fflush(stdout);
-
- for (command=1; command<=NUM_COMMANDS; command++) {
- mem_ctx = talloc_new(NULL);
- assert(mem_ctx != NULL);
-
- printf("%u.. ", command);
- fflush(stdout);
- fill_ctdb_event_reply_data(mem_ctx, &rd, command);
- buflen = ctdb_event_reply_data_len(&rd);
- ctdb_event_reply_data_push(&rd, BUFFER);
- ret = ctdb_event_reply_data_pull(BUFFER, buflen, mem_ctx, &rd2);
- assert(ret == 0);
- verify_ctdb_event_reply_data(&rd, &rd2);
-
- talloc_free(mem_ctx);
- }
-
- printf("\n");
- fflush(stdout);
-}
-