git.samba.org
/
bbaumbach
/
samba-autobuild
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e6105f9
)
ndrdump: Fix a possible NULL pointer dereference
author
Andreas Schneider
<asn@samba.org>
Thu, 16 Feb 2017 16:34:07 +0000
(17:34 +0100)
committer
Jeremy Allison
<jra@samba.org>
Thu, 23 Feb 2017 02:18:10 +0000
(
03:18
+0100)
Found by covscan.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12592
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
librpc/tools/ndrdump.c
patch
|
blob
|
history
diff --git
a/librpc/tools/ndrdump.c
b/librpc/tools/ndrdump.c
index b1e96b8a84232131d1e1f109fa1e427cae25b848..e26d371942985e4f85939097559c204e39f066d9 100644
(file)
--- a/
librpc/tools/ndrdump.c
+++ b/
librpc/tools/ndrdump.c
@@
-502,6
+502,10
@@
static void ndr_print_dummy(struct ndr_print *ndr, const char *format, ...)
bool differ;
ndr_v_push = ndr_push_init_ctx(mem_ctx);
+ if (ndr_v_push == NULL) {
+ printf("No memory\n");
+ exit(1);
+ }
if (assume_ndr64) {
ndr_v_push->flags |= LIBNDR_FLAG_NDR64;