nss_wins: Use lp_global_no_reinit()
authorAndreas Schneider <asn@samba.org>
Fri, 23 Oct 2015 13:28:23 +0000 (15:28 +0200)
committerVolker Lendecke <vl@samba.org>
Mon, 26 Oct 2015 20:23:21 +0000 (21:23 +0100)
This avoids that we run into use after free issues when we access memory
allocated on the globals and the global being reinitialized.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11563

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
nsswitch/wins.c

index 735a9a27dd714670ad1fc825363633642cf5968c..587ec30f83061c778c5a17ca1e236f46570d603d 100644 (file)
@@ -52,7 +52,7 @@ static void nss_wins_init(void)
 
        TimeInit();
        setup_logging("nss_wins",False);
-       lp_load_global(get_dyn_CONFIGFILE());
+       lp_load_global_no_reinit(get_dyn_CONFIGFILE());
        load_interfaces();
 }