From 2fcf85920deb2bb3e564c7be611b2cec838afbf1 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Mon, 14 Jun 2004 08:07:26 +0000 Subject: r1135: - allow integer function numbers in ndrdump - dump unused data in ndrdump (This used to be commit 65c5590bd0cd23c65a94786846740180c7f175ba) --- source4/utils/ndrdump.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source4') diff --git a/source4/utils/ndrdump.c b/source4/utils/ndrdump.c index 3bced67422..1b480c6c4d 100644 --- a/source4/utils/ndrdump.c +++ b/source4/utils/ndrdump.c @@ -40,6 +40,10 @@ static const struct dcerpc_interface_call *find_function( const char *function) { int i; + if (isdigit(function[0])) { + i = strtol(function, NULL, 0); + return &p->calls[i]; + } for (i=0;inum_calls;i++) { if (strcmp(p->calls[i].name, function) == 0) { break; @@ -161,6 +165,7 @@ static void show_functions(const struct dcerpc_interface_table *p) if (ndr->offset != ndr->data_size) { printf("WARNING! %d unread bytes\n", ndr->data_size - ndr->offset); + dump_data(0, ndr->data+ndr->offset, ndr->data_size - ndr->offset); } pr.mem_ctx = mem_ctx; -- cgit