Fix NULL pointer dereference in libgpo when listing Local Policy which has no securit...
authorWilco Baan Hofman <wilco@baanhofman.nl>
Sat, 10 Oct 2009 22:12:28 +0000 (00:12 +0200)
committerJelmer Vernooij <jelmer@samba.org>
Sun, 15 Nov 2009 18:26:50 +0000 (19:26 +0100)
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>
libgpo/gpo_util.c

index 7a23b5cbd37c6ea33024df4ee581779ca0de416e..fdf4c6d1af11003c2b701c588db471785bdb4ea1 100644 (file)
@@ -321,10 +321,11 @@ void dump_gpo(ADS_STRUCT *ads,
                }
                dump_gp_ext(gp_ext, lvl);
        }
                }
                dump_gp_ext(gp_ext, lvl);
        }
+       if (gpo->security_descriptor) {
+               DEBUGADD(lvl,("security descriptor:\n"));
 
 
-       DEBUGADD(lvl,("security descriptor:\n"));
-
-       NDR_PRINT_DEBUG(security_descriptor, gpo->security_descriptor);
+               NDR_PRINT_DEBUG(security_descriptor, gpo->security_descriptor);
+       }
 }
 
 /****************************************************************
 }
 
 /****************************************************************