r13212: r12414@cabra: derrell | 2006-01-28 17:52:17 -0500
authorDerrell Lipman <derrell@samba.org>
Sat, 28 Jan 2006 22:53:04 +0000 (22:53 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 16:06:18 +0000 (11:06 -0500)
 lp_load() could not be called multiple times to modify parameter settings based
 on reading from multiple configuration settings.  Each time, it initialized all
 of the settings back to their defaults before reading the specified
 configuration file.

 This patch adds a parameter to lp_load() specifying whether the settings should
 be initialized.  It does, however, still force the settings to be initialized
 the first time, even if the request was to not initialize them.  (Not doing so
 could wreak havoc due to uninitialized values.)

41 files changed:
source/client/client.c
source/client/smbctool.c
source/client/smbmount.c
source/client/smbspool.c
source/libsmb/libsmbclient.c
source/nmbd/nmbd.c
source/nsswitch/wbinfo.c
source/nsswitch/winbindd.c
source/nsswitch/wins.c
source/pam_smbpass/support.c
source/param/loadparm.c
source/python/py_common.c
source/rpcclient/rpcclient.c
source/smbd/server.c
source/smbwrapper/smbw.c
source/torture/locktest.c
source/torture/locktest2.c
source/torture/masktest.c
source/torture/msgtest.c
source/torture/rpctorture.c
source/torture/t_push_ucs2.c
source/torture/t_strcmp.c
source/torture/t_strstr.c
source/torture/torture.c
source/torture/vfstest.c
source/utils/eventlogadm.c
source/utils/net.c
source/utils/nmblookup.c
source/utils/ntlm_auth.c
source/utils/pdbedit.c
source/utils/smbcacls.c
source/utils/smbcontrol.c
source/utils/smbcquotas.c
source/utils/smbfilter.c
source/utils/smbpasswd.c
source/utils/smbtree.c
source/utils/smbw_sample.c
source/utils/status.c
source/utils/testparm.c
source/web/swat.c
source/wrepld/server.c

index 7ac64970f8128c76823bc0eb7c0ca3d7ca33d4a0..403074b22b88c4b4405c7fe51f13f9b2ec171926 100644 (file)
@@ -3449,7 +3449,7 @@ static int do_message_op(void)
        if ( override_logfile )
                setup_logging( lp_logfile(), False );
        
-       if (!lp_load(dyn_CONFIGFILE,True,False,False)) {
+       if (!lp_load(dyn_CONFIGFILE,True,False,False,True)) {
                fprintf(stderr, "%s: Can't load %s - run testparm to debug it\n",
                        argv[0], dyn_CONFIGFILE);
        }
index db938dd809662ed1e3647d736b6ea895ac4348e7..439345ca6deb9935023a5ca42498bb4f07d52bc9 100644 (file)
@@ -3654,7 +3654,7 @@ static int do_message_op(void)
        if ( override_logfile )
                setup_logging( lp_logfile(), False );
        
-       if (!lp_load(dyn_CONFIGFILE,True,False,False)) {
+       if (!lp_load(dyn_CONFIGFILE,True,False,False,True)) {
                fprintf(stderr, "%s: Can't load %s - run testparm to debug it\n",
                        argv[0], dyn_CONFIGFILE);
        }
index d8254ef23a7abbb47ac7723e55d64ce3a251a12b..21882ab2e96a39c714871cdc6632e979574bbde6 100644 (file)
@@ -910,7 +910,7 @@ static void parse_mount_smb(int argc, char **argv)
                pstrcpy(username,getenv("LOGNAME"));
        }
 
-       if (!lp_load(dyn_CONFIGFILE,True,False,False)) {
+       if (!lp_load(dyn_CONFIGFILE,True,False,False,True)) {
                fprintf(stderr, "Can't load %s - run testparm to debug it\n", 
                        dyn_CONFIGFILE);
        }
index 7fe918413d5fb0a5f64944e3cf8925782a9c53eb..d7a02b76f937014c62821b79ee3a0b10852771e3 100644 (file)
@@ -214,7 +214,7 @@ static int          smb_print(struct cli_state *, char *, FILE *);
 
   in_client = True;   /* Make sure that we tell lp_load we are */
 
-  if (!lp_load(dyn_CONFIGFILE, True, False, False))
+  if (!lp_load(dyn_CONFIGFILE, True, False, False, True))
   {
     fprintf(stderr, "ERROR: Can't load %s - run testparm to debug it\n", dyn_CONFIGFILE);
     return (1);
index 51f94e42e37bb78a05965f69507a8c8650adc9a5..fda619c5292e3521df3f9d842afd10f332eb589c 100644 (file)
@@ -6025,7 +6025,7 @@ smbc_init_context(SMBCCTX *context)
                 home = getenv("HOME");
                if (home) {
                        slprintf(conf, sizeof(conf), "%s/.smb/smb.conf", home);
-                       if (lp_load(conf, True, False, False)) {
+                       if (lp_load(conf, True, False, False, True)) {
                                conf_loaded = True;
                        } else {
                                 DEBUG(5, ("Could not load config file: %s\n",
@@ -6041,7 +6041,7 @@ smbc_init_context(SMBCCTX *context)
                          * defaults ...
                          */
 
-                        if (!lp_load(dyn_CONFIGFILE, True, False, False)) {
+                        if (!lp_load(dyn_CONFIGFILE, True, False, False, False)) {
                                 DEBUG(5, ("Could not load config file: %s\n",
                                           dyn_CONFIGFILE));
                         } else if (home) {
@@ -6052,7 +6052,7 @@ smbc_init_context(SMBCCTX *context)
                                  */
                                 slprintf(conf, sizeof(conf),
                                          "%s/.smb/smb.conf.append", home);
-                                if (!lp_load(conf, True, False, False)) {
+                                if (!lp_load(conf, True, False, False, False)) {
                                         DEBUG(10,
                                               ("Could not append config file: "
                                                "%s\n",
index ea7e9a5288f9b2e0baffd0f94b156b3c4bf51c37..f69cc32ff60d4b548f99b3c931f7f930750975fb 100644 (file)
@@ -291,7 +291,7 @@ static BOOL reload_nmbd_services(BOOL test)
        if ( test && !lp_file_list_changed() )
                return(True);
 
-       ret = lp_load( dyn_CONFIGFILE, True , False, False);
+       ret = lp_load( dyn_CONFIGFILE, True , False, False, True);
 
        /* perhaps the config filename is now set */
        if ( !test ) {
index f3819b6f51995d0c5c9e1a0ac5f2e2dc15939eff..b7c3b0a98c5b3cd478eee07fe8d702c2a2bfce35 100644 (file)
@@ -1024,7 +1024,7 @@ int main(int argc, char **argv)
        /* Samba client initialisation */
        load_case_tables();
 
-       if (!lp_load(dyn_CONFIGFILE, True, False, False)) {
+       if (!lp_load(dyn_CONFIGFILE, True, False, False, True)) {
                d_fprintf(stderr, "wbinfo: error opening config file %s. Error was %s\n",
                        dyn_CONFIGFILE, strerror(errno));
                exit(1);
index e9b9ed42c4f62f664a6e9d13ae80ad92bb01d5df..bbcf2b5e887ab0bf5378d4913705f484c0e8efa7 100644 (file)
@@ -47,7 +47,7 @@ static BOOL reload_services_file(void)
        }
 
        reopen_logs();
-       ret = lp_load(dyn_CONFIGFILE,False,False,True);
+       ret = lp_load(dyn_CONFIGFILE,False,False,True,True);
 
        reopen_logs();
        load_interfaces();
index ac5b0f11572a326b762e5cf2bf1ddce15a0620f6..f871a53982e05dc9cae4b8196a562841220e52e8 100644 (file)
@@ -80,7 +80,7 @@ static void nss_wins_init(void)
 
        TimeInit();
        setup_logging("nss_wins",False);
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
        load_interfaces();
 }
 
index 82d51103d26f4245f8b18f7417bdabcf1be3035c..3f2c638816003c46b51de2316f138a3a3e97bd2f 100644 (file)
@@ -167,7 +167,7 @@ int set_ctrl( int flags, int argc, const char **argv )
 
     /* Read some options from the Samba config. Can be overridden by
        the PAM config. */
-    if(lp_load(service_file,True,False,False) == False) {
+    if(lp_load(service_file,True,False,False,True) == False) {
        _log_err( LOG_ERR, "Error loading service file %s", service_file );
     }
 
index 83a5b2fc3cfa8717a30f491ed7cb836831e70369..a2aa851b095f918e15f04cdd2f291413aaff3426 100644 (file)
@@ -1354,11 +1354,17 @@ static void init_printer_values(service *pService)
  Initialise the global parameter structure.
 ***************************************************************************/
 
-static void init_globals(void)
+static void init_globals(BOOL first_time_only)
 {
        static BOOL done_init = False;
        pstring s;
 
+        /* If requested to initialize only once and we've already done it... */
+        if (first_time_only && done_init) {
+                /* ... then we have nothing more to do */
+                return;
+        }
+
        if (!done_init) {
                int i;
 
@@ -4188,8 +4194,11 @@ static void set_allowed_client_auth(void)
  False on failure.
 ***************************************************************************/
 
-BOOL lp_load(const char *pszFname, BOOL global_only, BOOL save_defaults,
-            BOOL add_ipc)
+BOOL lp_load(const char *pszFname,
+             BOOL global_only,
+             BOOL save_defaults,
+            BOOL add_ipc,
+             BOOL initialize_globals)
 {
        pstring n2;
        BOOL bRetval;
@@ -4208,7 +4217,7 @@ BOOL lp_load(const char *pszFname, BOOL global_only, BOOL save_defaults,
        bInGlobalSection = True;
        bGlobalOnly = global_only;
 
-       init_globals();
+       init_globals(! initialize_globals);
        debug_init();
 
        if (save_defaults) {
index 66f35759c3d6d56b2c4c6600a79b8699d4e90eff..70d478b9797fae75fef9117d6424508c97a957e2 100644 (file)
@@ -47,7 +47,7 @@ void py_samba_init(void)
 
        /* Load configuration file */
 
-       if (!lp_load(dyn_CONFIGFILE, True, False, False))
+       if (!lp_load(dyn_CONFIGFILE, True, False, False, True))
                fprintf(stderr, "Can't load %s\n", dyn_CONFIGFILE);
 
        /* Misc other stuff */
index 5bca67d7a63f6d0557b6c8f92871d980f143d433..5e66b18263005613e9090770a1e25e39cfe768ce 100644 (file)
@@ -757,7 +757,7 @@ out_free:
 
        /* Load smb.conf file */
 
-       if (!lp_load(dyn_CONFIGFILE,True,False,False))
+       if (!lp_load(dyn_CONFIGFILE,True,False,False,True))
                fprintf(stderr, "Can't load %s\n", dyn_CONFIGFILE);
 
        /*
index 620bf3ebbdd2d15f6d4de263fb31829a8cda8806..3e970ec16c2a8d5213836a43241ec15e39b7e362 100644 (file)
@@ -529,7 +529,7 @@ BOOL reload_services(BOOL test)
 
        lp_killunused(conn_snum_used);
 
-       ret = lp_load(dyn_CONFIGFILE, False, False, True);
+       ret = lp_load(dyn_CONFIGFILE, False, False, True, True);
 
        reload_printers();
 
index edcc7a5c2f958568b4a0724d76715acf3646c12b..d4a5b51af4e27c02699984a5f5c356608fa2d762 100644 (file)
@@ -76,7 +76,7 @@ void smbw_init(void)
                pstrcpy(dyn_CONFIGFILE, p);
        }
 
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
 
        if (!init_names())
                exit(1);
index c8336ebaf66daf90ab0098be033515e22f71260f..913df885baeb6bf8cfe554502b81fe3866912f2a 100644 (file)
@@ -586,7 +586,7 @@ static void usage(void)
        argc -= NSERVERS;
        argv += NSERVERS;
 
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
        load_interfaces();
 
        if (getenv("USER")) {
index fc180bfafe22513d35e6f096967c68dc10051031..519acebe8e81413621b1b66a69139aa78ce6d00e 100644 (file)
@@ -498,7 +498,7 @@ static void usage(void)
        argc -= 4;
        argv += 4;
 
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
        load_interfaces();
 
        if (getenv("USER")) {
index 07bfe6912172574d185b246a04ffaa2e365f9cc4..ffc9a20e71cdd3c6ee35bb8e07f8d7578807f6cd 100644 (file)
@@ -454,7 +454,7 @@ static void usage(void)
        argc -= 1;
        argv += 1;
 
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
        load_interfaces();
 
        if (getenv("USER")) {
index d691ab32f1db7e7574ca645a0f27f1e6f3b702ef..f7c47ddbbf8a674e0336499d43301a24d65887eb 100644 (file)
@@ -41,7 +41,7 @@ void pong_message(int msg_type, struct process_id src, void *buf, size_t len)
 
        setup_logging(argv[0],True);
        
-       lp_load(dyn_CONFIGFILE,False,False,False);
+       lp_load(dyn_CONFIGFILE,False,False,False,True);
 
        message_init();
 
index 28067c1a0ae73b3f8f48441cd735016eb256a0f8..d69cc8eb8df9abe387d2cd8ccb60e102a75cba7d 100644 (file)
@@ -242,7 +242,7 @@ enum client_action
        *term_code = 0;
 #endif /* KANJI */
 
-       if (!lp_load(dyn_CONFIGFILE,True, False, False))
+       if (!lp_load(dyn_CONFIGFILE,True, False, False, True))
        {
                fprintf(stderr, "Can't load %s - run testparm to debug it\n", dyn_CONFIGFILE);
        }
index 8bfc6f7ad9e4c973ebe101ee1e8ad3fafe72fb85..8d327acfa563b7a1978dad0260885a35be3067f3 100644 (file)
@@ -33,7 +33,7 @@ int main(int argc, char *argv[])
        int count = 1;
 
        /* Needed to initialize character set */
-       lp_load("/dev/null", True, False, False);
+       lp_load("/dev/null", True, False, False, True);
 
        if (argc < 2) {
                fprintf(stderr, "usage: %s STRING1 [COUNT]\n"
index bc8640ee550c350feefa4f2e300e69163de0af22..318423b8be00919a83870f313582b96620f7760f 100644 (file)
@@ -12,7 +12,7 @@ int main(int argc, char *argv[])
        int iters = 1;
        
        /* Needed to initialize character set */
-       lp_load("/dev/null", True, False, False);
+       lp_load("/dev/null", True, False, False, True);
 
        if (argc < 3) {
                fprintf(stderr, "usage: %s STRING1 STRING2 [ITERS]\n"
index 7b928fb26bea41f017526aa3c317a7866eeb7001..49180b219f7e5ddaf9dee3f12a9d3be763abad2d 100644 (file)
@@ -14,7 +14,7 @@ int main(int argc, char *argv[])
        const char *ret = NULL;
 
        /* Needed to initialize character set */
-       lp_load("/dev/null", True, False, False);
+       lp_load("/dev/null", True, False, False, True);
 
        if (argc < 3) {
                fprintf(stderr, "usage: %s STRING1 STRING2 [ITERS]\n"
index e995c3cc58a73b88bbd0d9f771a0172836ce18a4..0b3bfc18f4af76957f5d9458001a27b20fa426c5 100644 (file)
@@ -4916,7 +4916,7 @@ static void usage(void)
 
        load_case_tables();
 
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
        load_interfaces();
 
        if (argc < 2) {
index 1914a4acb50ba752c67ff93b43178bdb71aaef5a..023e656c6727bb1812dc485e84ff8516f622f070 100644 (file)
@@ -113,7 +113,7 @@ static NTSTATUS cmd_conf(struct vfs_state *vfs, TALLOC_CTX *mem_ctx,
                return NT_STATUS_OK;
        }
 
-       if (!lp_load(argv[1], False, True, False)) {
+       if (!lp_load(argv[1], False, True, False, True)) {
                printf("Error loading \"%s\"\n", argv[1]);
                return NT_STATUS_OK;
        }
@@ -448,7 +448,7 @@ BOOL reload_services(BOOL test)
 
        lp_killunused(conn_snum_used);
        
-       ret = lp_load(dyn_CONFIGFILE, False, False, True);
+       ret = lp_load(dyn_CONFIGFILE, False, False, True, True);
 
        /* perhaps the config filename is now set */
        if (!test)
index eef7cde3771f650fb0ee0f58109e90762ea01dc2..8cf79fcf14b55e6c0e8a2368272e04d8697e906e 100644 (file)
@@ -170,7 +170,7 @@ int main( int argc, char *argv[] )
 
        opt_debug = 0;          /* todo set this from getopts */
 
-       lp_load( dyn_CONFIGFILE, True, False, False );
+       lp_load( dyn_CONFIGFILE, True, False, False, True);
 
        exename = argv[0];
        srcname = NULL;
index a2a9ac6a3918869eadffe26dafb38b515a44f906..25e10c6a316de1253829cac09889809dbe881c1f 100644 (file)
@@ -825,7 +825,7 @@ static struct functable net_func[] = {
         * set by cmdline arg or remain default (0)
         */
        AllowDebugChange = False;
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
        
        argv_new = (const char **)poptGetArgs(pc);
 
index e88d78629016ac1b10449f2093cccc906d8a20df..12ac1beb7b1bed5e2f47e7fa5a62e04bb62f011a 100644 (file)
@@ -248,7 +248,7 @@ int main(int argc,char *argv[])
          exit(1);
   }
 
-  if (!lp_load(dyn_CONFIGFILE,True,False,False)) {
+  if (!lp_load(dyn_CONFIGFILE,True,False,False,True)) {
          fprintf(stderr, "Can't load %s - run testparm to debug it\n", dyn_CONFIGFILE);
   }
 
index 65dbfb71650018840fdbb31400dac9a962c01a6a..4759aec0ccff5932985ae1fc0fa95b4ae7078c93 100644 (file)
@@ -1758,7 +1758,7 @@ enum {
        
        /* Samba client initialisation */
 
-       if (!lp_load(dyn_CONFIGFILE, True, False, False)) {
+       if (!lp_load(dyn_CONFIGFILE, True, False, False, True)) {
                d_fprintf(stderr, "ntlm_auth: error opening config file %s. Error was %s\n",
                        dyn_CONFIGFILE, strerror(errno));
                exit(1);
index 53d3b17d064b9289a08b7bae02f338993196b12a..f41bbb8caaf90953ae5fbc2b677f40d1bb706772 100644 (file)
@@ -795,7 +795,7 @@ int main (int argc, char **argv)
        if (user_name == NULL)
                user_name = poptGetArg(pc);
 
-       if (!lp_load(dyn_CONFIGFILE,True,False,False)) {
+       if (!lp_load(dyn_CONFIGFILE,True,False,False,True)) {
                fprintf(stderr, "Can't load %s - run testparm to debug it\n", dyn_CONFIGFILE);
                exit(1);
        }
index cbbd7adaab39d500a4d5948385d9ff48c9316cf0..26362c6270a03bc816b50924e08cd997b1f30bb8 100644 (file)
@@ -830,7 +830,7 @@ static struct cli_state *connect_one(const char *share)
 
        setlinebuf(stdout);
 
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
        load_interfaces();
 
        pc = poptGetContext("smbcacls", argc, argv, long_options, 0);
index b8f7c2f2b553e5d30f8314ccf658585693e1e1d7..a4d2766b13281ea93c80750cfd812d18dabc6e0d 100644 (file)
@@ -827,7 +827,7 @@ int main(int argc, const char **argv)
        if (argc == 1)
                usage(&pc);
 
-       lp_load(dyn_CONFIGFILE,False,False,False);
+       lp_load(dyn_CONFIGFILE,False,False,False,True);
 
        /* Need to invert sense of return code -- samba
          * routines mostly return True==1 for success, but
index f8e33131555cb74f3f8a0b325effa779975ea84c..b1a14685f5eccdfa7a45dc83a6650583c92809a1 100644 (file)
@@ -435,7 +435,7 @@ FSQFLAGS:QUOTA_ENABLED/DENY_DISK/LOG_SOFTLIMIT/LOG_HARD_LIMIT", "SETSTRING" },
 
        fault_setup(NULL);
 
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
        load_interfaces();
 
        pc = poptGetContext("smbcquotas", argc, argv, long_options, 0);
index 3665647905d9aac9bf8152529e1bc46bc87e7d9f..97d22230c4bb56c44086a2d5d4570fe25f04b0e6 100644 (file)
@@ -236,7 +236,7 @@ int main(int argc, char *argv[])
                netbiosname = argv[2];
        }
 
-       if (!lp_load(configfile,True,False,False)) {
+       if (!lp_load(configfile,True,False,False,True)) {
                d_printf("Unable to load config file\n");
        }
 
index 29189c5febd9cb27902b4d3c1d066548cc4b641a..7eb11137d707ab84d41667f029e57f223c8e8330 100644 (file)
@@ -187,7 +187,7 @@ static int process_options(int argc, char **argv, int local_flags)
                usage();
        }
 
-       if (!lp_load(configfile,True,False,False)) {
+       if (!lp_load(configfile,True,False,False,True)) {
                fprintf(stderr, "Can't load %s - run testparm to debug it\n", 
                        dyn_CONFIGFILE);
                exit(1);
index 3755b7f8e55c487418ecb7b974d678718952ba7f..853a46f379e6bac598465840baea264e2e8b4dd6 100644 (file)
@@ -216,7 +216,7 @@ static BOOL print_tree(struct user_auth_info *user_info)
        while(poptGetNextOpt(pc) != -1);
        poptFreeContext(pc);
 
-       lp_load(dyn_CONFIGFILE,True,False,False);
+       lp_load(dyn_CONFIGFILE,True,False,False,True);
        load_interfaces();
 
        /* Parse command line args */
index 5cd792df7a2f62cde225f83247f5692e995895e6..ba78eb22fc79c0f904f35bf153a70b921e40bdaa 100644 (file)
@@ -33,7 +33,7 @@ int main(int argc, char *argv[])
        extern int optind;
        char *path;
 
-       lp_load(dyn_CONFIGFILE,1,0,0);
+       lp_load(dyn_CONFIGFILE,1,0,0,1);
        smbw_setup_shared();
 
        while ((opt = getopt(argc, argv, "W:U:R:d:P:l:hL:")) != EOF) {
index eeaf83d17728975fd0b5da69e86d39e7f60e4f35..2aed68be89717a83152be423037276caf2ffa970 100644 (file)
@@ -648,7 +648,7 @@ static int traverse_sessionid(TDB_CONTEXT *tdb, TDB_DATA kbuf, TDB_DATA dbuf, vo
                d_printf("using configfile = %s\n", dyn_CONFIGFILE);
        }
 
-       if (!lp_load(dyn_CONFIGFILE,False,False,False)) {
+       if (!lp_load(dyn_CONFIGFILE,False,False,False,True)) {
                fprintf(stderr, "Can't load %s - run testparm to debug it\n", dyn_CONFIGFILE);
                return (-1);
        }
index 11ce960e557a2b7bd1791a3e5e0fdd9f8993209b..8b9ff4710e00ef44080b1543b2c51b49e9e18a15 100644 (file)
@@ -266,7 +266,7 @@ via the %%o substitution. With encrypted passwords this is not possible.\n", lp_
 
        fprintf(stderr,"Load smb config files from %s\n",config_file);
 
-       if (!lp_load(config_file,False,True,False)) {
+       if (!lp_load(config_file,False,True,False,True)) {
                fprintf(stderr,"Error loading services.\n");
                return(1);
        }
index 372d473bdb568a356853a3784310c7e7fb5b8417..63253e41c40f69ae26344975f31142615466908d 100644 (file)
@@ -422,7 +422,7 @@ static void show_parameters(int snum, int allparameters, unsigned int parm_filte
 static BOOL load_config(BOOL save_def)
 {
        lp_resetnumservices();
-       return lp_load(dyn_CONFIGFILE,False,save_def,False);
+       return lp_load(dyn_CONFIGFILE,False,save_def,False,True);
 }
 
 /****************************************************************************
index 5ac78a247452e5af967494b805c6175a52d95687..754bad01b0d0f5348a6dc876cbf08ae7250862d1 100644 (file)
@@ -64,7 +64,7 @@ BOOL reload_services(BOOL test)
        if (test && !lp_file_list_changed())
                return(True);
 
-       ret = lp_load(dyn_CONFIGFILE,False,False,True);
+       ret = lp_load(dyn_CONFIGFILE,False,False,True,True);
 
 
        /* perhaps the config filename is now set */