Ooops... forgot to attach the patch..
Index: source/passdb/pdb_interface.c
===================================================================
RCS file: /cvsroot/samba/source/passdb/pdb_interface.c,v
retrieving revision 1.12
diff -u -3 -p -r1.12 pdb_interface.c
--- source/passdb/pdb_interface.c 13 Apr 2002 09:35:51 -0000 1.12
+++ source/passdb/pdb_interface.c 3 May 2002 13:36:50 -0000
@@ -240,7 +240,7 @@ static NTSTATUS make_pdb_methods_name(st
{
DEBUG(5,("Found pdb backend %s (at pos %d)\n", module_name,
i));
if (NT_STATUS_IS_OK(nt_status
- =
builtin_pdb_init_functions[i].init(context, methods, module_location))) {
+ =
+builtin_pdb_init_functions[i].init(context, methods, module_location))) {
DEBUG(5,("pdb backend %s has a valid init\n",
selected));
} else {
DEBUG(0,("pdb backend %s did not correctly init (error
was %s)\n", selected, nt_errstr(nt_status)));
@@ -251,9 +251,8 @@ static NTSTATUS make_pdb_methods_name(st
if (!*methods) {
DEBUG(0,("failed to select passdb backed!\n"));
- return nt_status;
}
- return NT_STATUS_OK;
+ return nt_status;
}
/******************************************************************
@@ -326,26 +325,27 @@ NTSTATUS make_pdb_context_name(struct pd
DEBUG(5,("Trying to load: %s\n", confcur));
if(!NT_STATUS_IS_OK(make_pdb_methods_name(&curmethods, *context,
confcur))){
DEBUG(5, ("Loading %s failed!\n", confcur));
- SAFE_FREE(curmethods);
- continue;
- }
- curmethods->parent = *context;
- DLIST_ADD_END((*context)->pdb_methods, curmethods, tmpmethods);
+ }else{
+ DEBUG(5, ("Loading %s succeeded!\n", confcur));
+ /* If at least one methods can be loaded, then
+ * this function should succeed */
+ nt_status = NT_STATUS_OK;
+ curmethods->parent = *context;
+ DLIST_ADD_END((*context)->pdb_methods, curmethods, tmpmethods);
+ }
if(!confnext)break;
confcur = confnext;
}
SAFE_FREE(conf);
-
- nt_status = NT_STATUS_OK;
-
+
return nt_status;
}
msg00541/pgp00000.pgp
Description: PGP signature