summaryrefslogtreecommitdiff
path: root/source3/winbindd
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2011-03-13 10:41:27 +0100
committerVolker Lendecke <vlendec@samba.org>2011-03-13 12:59:37 +0100
commit51ebaac75b8d068766872b156c3a4507ddc0705a (patch)
treec416acda8ba39871d1e539488ea6c5212fe0b4f7 /source3/winbindd
parent4d4c6315fa65b9938d1b4222832d12055c46e681 (diff)
downloadsamba-51ebaac75b8d068766872b156c3a4507ddc0705a.tar.gz
samba-51ebaac75b8d068766872b156c3a4507ddc0705a.tar.bz2
samba-51ebaac75b8d068766872b156c3a4507ddc0705a.zip
s3: Enhance error messages in idmap_tdb2_init_hwm
Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Sun Mar 13 12:59:37 CET 2011 on sn-devel-104
Diffstat (limited to 'source3/winbindd')
-rw-r--r--source3/winbindd/idmap_tdb2.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/source3/winbindd/idmap_tdb2.c b/source3/winbindd/idmap_tdb2.c
index ebb186b2f8..05d408ac1e 100644
--- a/source3/winbindd/idmap_tdb2.c
+++ b/source3/winbindd/idmap_tdb2.c
@@ -57,6 +57,7 @@ struct idmap_tdb2_context {
*/
static NTSTATUS idmap_tdb2_init_hwm(struct idmap_domain *dom)
{
+ NTSTATUS status;
uint32 low_id;
struct idmap_tdb2_context *ctx;
@@ -66,22 +67,22 @@ static NTSTATUS idmap_tdb2_init_hwm(struct idmap_domain *dom)
low_id = dbwrap_fetch_int32(ctx->db, HWM_USER);
if ((low_id == -1) || (low_id < dom->low_id)) {
- if (!NT_STATUS_IS_OK(dbwrap_trans_store_int32(
- ctx->db, HWM_USER,
- dom->low_id))) {
+ status = dbwrap_trans_store_int32(ctx->db, HWM_USER,
+ dom->low_id);
+ if (!NT_STATUS_IS_OK(status)) {
DEBUG(0, ("Unable to initialise user hwm in idmap "
- "database\n"));
+ "database: %s\n", nt_errstr(status)));
return NT_STATUS_INTERNAL_DB_ERROR;
}
}
low_id = dbwrap_fetch_int32(ctx->db, HWM_GROUP);
if ((low_id == -1) || (low_id < dom->low_id)) {
- if (!NT_STATUS_IS_OK(dbwrap_trans_store_int32(
- ctx->db, HWM_GROUP,
- dom->low_id))) {
+ status = dbwrap_trans_store_int32(ctx->db, HWM_GROUP,
+ dom->low_id);
+ if (!NT_STATUS_IS_OK(status)) {
DEBUG(0, ("Unable to initialise group hwm in idmap "
- "database\n"));
+ "database: %s\n", nt_errstr(status)));
return NT_STATUS_INTERNAL_DB_ERROR;
}
}