summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAmitay Isaacs <amitay@gmail.com>2011-08-12 15:44:39 +1000
committerAndrew Bartlett <abartlet@samba.org>2011-08-13 12:30:50 +1000
commitd7ab07e86f421de1cb4dbd3905ec2567f0e34c1b (patch)
tree2cba951c53bb87d7dd714fbd9493d26c370519ff /source3
parentae65b971ac1492da53b1259d113f686504e570cd (diff)
downloadsamba-d7ab07e86f421de1cb4dbd3905ec2567f0e34c1b.tar.gz
samba-d7ab07e86f421de1cb4dbd3905ec2567f0e34c1b.tar.bz2
samba-d7ab07e86f421de1cb4dbd3905ec2567f0e34c1b.zip
s3-passdb: Fix the error messages and return correct NTSTATUS
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'source3')
-rw-r--r--source3/passdb/pdb_samba4.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/source3/passdb/pdb_samba4.c b/source3/passdb/pdb_samba4.c
index df51dc1660..ed27501b4d 100644
--- a/source3/passdb/pdb_samba4.c
+++ b/source3/passdb/pdb_samba4.c
@@ -2203,14 +2203,14 @@ static NTSTATUS pdb_init_samba4(struct pdb_methods **pdb_method,
state->ev = s4_event_context_init(state);
if (!state->ev) {
- DEBUG(10, ("s4_event_context_init failed\n"));
- goto fail;
+ DEBUG(0, ("s4_event_context_init failed\n"));
+ goto nomem;
}
state->lp_ctx = loadparm_init_s3(state, loadparm_s3_context());
if (state->lp_ctx == NULL) {
- DEBUG(10, ("loadparm_init_s3 failed\n"));
- goto fail;
+ DEBUG(0, ("loadparm_init_s3 failed\n"));
+ goto nomem;
}
state->ldb = samdb_connect(state,
@@ -2219,14 +2219,16 @@ static NTSTATUS pdb_init_samba4(struct pdb_methods **pdb_method,
system_session(state->lp_ctx), 0);
if (!state->ldb) {
- DEBUG(10, ("samdb_connect failed\n"));
+ DEBUG(0, ("samdb_connect failed\n"));
+ status = NT_STATUS_INTERNAL_ERROR;
goto fail;
}
state->idmap_ctx = idmap_init(state, state->ev,
state->lp_ctx);
if (!state->idmap_ctx) {
- DEBUG(10, ("samdb_connect failed\n"));
+ DEBUG(0, ("idmap failed\n"));
+ status = NT_STATUS_INTERNAL_ERROR;
goto fail;
}