diff options
Diffstat (limited to 'source3/winbindd')
-rw-r--r-- | source3/winbindd/idmap_autorid.c | 11 | ||||
-rw-r--r-- | source3/winbindd/idmap_tdb.c | 4 | ||||
-rw-r--r-- | source3/winbindd/idmap_tdb_common.c | 2 |
3 files changed, 9 insertions, 8 deletions
diff --git a/source3/winbindd/idmap_autorid.c b/source3/winbindd/idmap_autorid.c index df63fa9920..d02f34e573 100644 --- a/source3/winbindd/idmap_autorid.c +++ b/source3/winbindd/idmap_autorid.c @@ -68,7 +68,7 @@ static NTSTATUS idmap_autorid_get_domainrange_action(struct db_context *db, cfg = (struct autorid_domain_config *)private_data; - ret = dbwrap_fetch_uint32(db, cfg->sid, &(cfg->domainnum)); + ret = dbwrap_fetch_uint32_bystring(db, cfg->sid, &(cfg->domainnum)); if (NT_STATUS_IS_OK(ret)) { /* entry is already present*/ @@ -78,7 +78,7 @@ static NTSTATUS idmap_autorid_get_domainrange_action(struct db_context *db, DEBUG(10, ("Acquiring new range for domain %s\n", cfg->sid)); /* fetch the current HWM */ - ret = dbwrap_fetch_uint32(db, HWM, &hwm); + ret = dbwrap_fetch_uint32_bystring(db, HWM, &hwm); if (!NT_STATUS_IS_OK(ret)) { DEBUG(1, ("Fatal error while fetching current " "HWM value: %s\n", nt_errstr(ret))); @@ -146,7 +146,8 @@ static NTSTATUS idmap_autorid_get_domainrange(struct autorid_domain_config *dom, * if it is not found create a mapping in a transaction unless * read-only mode has been set */ - ret = dbwrap_fetch_uint32(autorid_db, dom->sid, &(dom->domainnum)); + ret = dbwrap_fetch_uint32_bystring(autorid_db, dom->sid, + &(dom->domainnum)); if (!NT_STATUS_IS_OK(ret)) { if (read_only) { @@ -605,7 +606,7 @@ static NTSTATUS idmap_autorid_init_hwm(const char *hwm) { NTSTATUS status; uint32_t hwmval; - status = dbwrap_fetch_uint32(autorid_db, hwm, &hwmval); + status = dbwrap_fetch_uint32_bystring(autorid_db, hwm, &hwmval); if (NT_STATUS_EQUAL(status, NT_STATUS_NOT_FOUND)) { status = dbwrap_trans_store_int32(autorid_db, hwm, 0); if (!NT_STATUS_IS_OK(status)) { @@ -843,7 +844,7 @@ static NTSTATUS idmap_autorid_initialize(struct idmap_domain *dom) /* read previously stored config and current HWM */ storedconfig = idmap_autorid_loadconfig(talloc_tos()); - status = dbwrap_fetch_uint32(autorid_db, HWM, &hwm); + status = dbwrap_fetch_uint32_bystring(autorid_db, HWM, &hwm); if (!NT_STATUS_IS_OK(status)) { DEBUG(1, ("Fatal error while fetching current " "HWM value: %s\n", nt_errstr(status))); diff --git a/source3/winbindd/idmap_tdb.c b/source3/winbindd/idmap_tdb.c index 3e46cf76b7..4c3b4b190a 100644 --- a/source3/winbindd/idmap_tdb.c +++ b/source3/winbindd/idmap_tdb.c @@ -258,12 +258,12 @@ static NTSTATUS idmap_tdb_init_hwm(struct idmap_domain *dom) ctx = talloc_get_type(dom->private_data, struct idmap_tdb_common_context); - status = dbwrap_fetch_uint32(ctx->db, HWM_USER, &low_uid); + status = dbwrap_fetch_uint32_bystring(ctx->db, HWM_USER, &low_uid); if (!NT_STATUS_IS_OK(status) || low_uid < dom->low_id) { update_uid = true; } - status = dbwrap_fetch_uint32(ctx->db, HWM_GROUP, &low_gid); + status = dbwrap_fetch_uint32_bystring(ctx->db, HWM_GROUP, &low_gid); if (!NT_STATUS_IS_OK(status) || low_gid < dom->low_id) { update_gid = true; } diff --git a/source3/winbindd/idmap_tdb_common.c b/source3/winbindd/idmap_tdb_common.c index ca6f6d8e08..1c2e3467b2 100644 --- a/source3/winbindd/idmap_tdb_common.c +++ b/source3/winbindd/idmap_tdb_common.c @@ -56,7 +56,7 @@ static NTSTATUS idmap_tdb_common_allocate_id_action(struct db_context *db, state = (struct idmap_tdb_common_allocate_id_context *)private_data; - ret = dbwrap_fetch_uint32(db, state->hwmkey, &hwm); + ret = dbwrap_fetch_uint32_bystring(db, state->hwmkey, &hwm); if (!NT_STATUS_IS_OK(ret)) { ret = NT_STATUS_INTERNAL_DB_ERROR; goto done; |