s3:registry: always provision the registry, not only in smbd.
authorMichael Adam <obnox@samba.org>
Wed, 28 Jan 2009 11:04:53 +0000 (12:04 +0100)
committerMichael Adam <obnox@samba.org>
Wed, 28 Jan 2009 11:06:26 +0000 (12:06 +0100)
This will make tools like "net registry" also fill the registry
with the basic hives and keys.

Michael

source3/registry/reg_init_basic.c
source3/registry/reg_init_full.c

index 60dcabdcf2f3f2771c1c73fba0d95a1951b94a70..eab4ca7f9d62b3501401d9a46493f33e48f3ab77 100644 (file)
@@ -37,6 +37,14 @@ WERROR registry_init_common(void)
        if (!W_ERROR_IS_OK(werr)) {
                DEBUG(0, ("Failed to initialize the reghook cache: %s\n",
                          win_errstr(werr)));
+               goto done;
+       }
+
+       /* setup the necessary keys and values */
+
+       werr = init_registry_data();
+       if (!W_ERROR_IS_OK(werr)) {
+               DEBUG(0, ("Failed to initialize data in registry!\n"));
        }
 
 done:
index 91e55d76b24f3d77594893e724ea283896caf466..b5a06f25826521414e0d0af823fa4e1bf8134a6b 100644 (file)
@@ -72,14 +72,6 @@ WERROR registry_init_full(void)
                goto fail;
        }
 
-       /* setup the necessary keys and values */
-
-       werr = init_registry_data();
-       if (!W_ERROR_IS_OK(werr)) {
-               DEBUG(0, ("Failed to initialize data in registry!\n"));
-               goto fail;
-       }
-
        /* build the cache tree of registry hooks */
 
        for ( i=0; reg_hooks[i].keyname; i++ ) {