return p;
}
+static void printf_cb(const char *buf, void *private_data)
+{
+ printf("%s", buf);
+}
+
static void ndrdump_data(uint8_t *d, uint32_t l, bool force)
{
- if (force) {
- dump_data(0, d, l);
- } else {
- dump_data_skip_zeros(0, d, l);
- }
+ dump_data_cb(d, l, !force, printf_cb, NULL);
}
int main(int argc, const char *argv[])
{ NULL }
};
- if (DEBUGLEVEL < 1) {
- DEBUGLEVEL = 1;
- }
-
ndr_table_init();
/* Initialise samba stuff */
setlinebuf(stdout);
- dbf = x_stderr;
-
setup_logging_stdout();
pc = poptGetContext("ndrdump", argc, argv, long_options, 0);
}
ndr_print = talloc_zero(mem_ctx, struct ndr_print);
- ndr_print->print = ndr_print_debug_helper;
+ ndr_print->print = ndr_print_printf_helper;
ndr_print->depth = 1;
f->ndr_print(ndr_print, function, flags, st);