summaryrefslogtreecommitdiffstats
path: root/source4/libnet
diff options
context:
space:
mode:
authorMatthias Dieter Wallnöfer <mdw@samba.org>2010-12-07 14:57:17 +0100
committerMatthias Dieter Wallnöfer <mdw@samba.org>2010-12-07 15:19:14 +0100
commita07d20821ac9d09831bac10eca91ae8cb7b5106f (patch)
tree0abd55beffe3e4d850f1625b137e4c93367a3aff /source4/libnet
parentd91189727adf6b4cbe219da71a21bfc7bc2bff7f (diff)
downloadsamba-a07d20821ac9d09831bac10eca91ae8cb7b5106f.tar.gz
samba-a07d20821ac9d09831bac10eca91ae8cb7b5106f.tar.xz
samba-a07d20821ac9d09831bac10eca91ae8cb7b5106f.zip
s4:libnet_samsync_ldb.c - introduce an error message on failed domain synchronisation
Diffstat (limited to 'source4/libnet')
-rw-r--r--source4/libnet/libnet_samsync_ldb.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/source4/libnet/libnet_samsync_ldb.c b/source4/libnet/libnet_samsync_ldb.c
index 9626341104e..187abb70a19 100644
--- a/source4/libnet/libnet_samsync_ldb.c
+++ b/source4/libnet/libnet_samsync_ldb.c
@@ -222,9 +222,12 @@ static NTSTATUS samsync_ldb_handle_domain(TALLOC_CTX *mem_ctx,
/* TODO: Account lockout, password properties */
ret = dsdb_replace(state->sam_ldb, msg, 0);
-
- if (ret) {
- return NT_STATUS_INTERNAL_ERROR;
+ if (ret != LDB_SUCCESS) {
+ *error_string = talloc_asprintf(mem_ctx,
+ "Failed to modify domain record %s: %s",
+ ldb_dn_get_linearized(msg->dn),
+ ldb_errstring(state->sam_ldb));
+ return NT_STATUS_INTERNAL_DB_CORRUPTION;
}
return NT_STATUS_OK;
}