* create each component key of the specified path,
* wrapped in one db transaction.
*/
-static bool init_registry_key(const char *add_path)
+bool init_registry_key(const char *add_path)
{
if (regdb->transaction_start(regdb) == -1) {
DEBUG(0, ("init_registry_key: transaction_start failed\n"));
Open the registry data in the tdb
***********************************************************************/
-static bool init_registry_data(void)
+bool init_registry_data(void)
{
TALLOC_CTX *frame = NULL;
REGVAL_CTR *values;
vers_id, REGVER_V1));
}
- /* always setup the necessary keys and values */
-
- if ( !init_registry_data() ) {
- DEBUG(0,("regdb_init: Failed to initialize data in registry!\n"));
- return false;
- }
-
return true;
}
goto fail;
}
+ /* setup the necessary keys and values */
+
+ if ( !init_registry_data() ) {
+ DEBUG(0,("regdb_init: Failed to initialize data in registry!\n"));
+ return false;
+ }
+
/* build the cache tree of registry hooks */
reghook_cache_init();
DEBUGADD(1, (".\n"));
goto done;
}
+ if (!init_registry_key(KEY_SMBCONF)) {
+ DEBUG(1, ("Could not initialize registry key '%s'\n",
+ KEY_SMBCONF));
+ goto done;
+ }
reghook_cache_init();
if (!reghook_cache_add(&smbconf_reg_hook)) {
DEBUG(1, ("Error adding smbconf reghooks to reghook cache.\n"));