summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2009-07-03 17:18:19 +0200
committerMichael Adam <obnox@samba.org>2009-07-15 14:01:44 +0200
commitdb4f797e3533b97df844a50a92e8a27a9248092b (patch)
tree07a2a9fe9d75342efa0f46d0b07fe8df860bd1b2
parentc01d955ac0b6ef686cf026cc90074cd52a1a30ae (diff)
downloadsamba-db4f797e3533b97df844a50a92e8a27a9248092b.tar.gz
samba-db4f797e3533b97df844a50a92e8a27a9248092b.tar.bz2
samba-db4f797e3533b97df844a50a92e8a27a9248092b.zip
s3:registry: add db_context argument to scan_parent_subkeys()
Michael
-rw-r--r--source3/registry/reg_backend_db.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/source3/registry/reg_backend_db.c b/source3/registry/reg_backend_db.c
index 165c0abf59..562e29742d 100644
--- a/source3/registry/reg_backend_db.c
+++ b/source3/registry/reg_backend_db.c
@@ -1245,7 +1245,8 @@ static int parent_subkey_scanner(TDB_DATA key, TDB_DATA data,
return 0;
}
-static bool scan_parent_subkeys(const char *parent, const char *name)
+static bool scan_parent_subkeys(struct db_context *db, const char *parent,
+ const char *name)
{
char *path = NULL;
char *key = NULL;
@@ -1272,8 +1273,8 @@ static bool scan_parent_subkeys(const char *parent, const char *name)
}
state.scanned = false;
- res = regdb->parse_record(regdb, string_term_tdb_data(key),
- parent_subkey_scanner, &state);
+ res = db->parse_record(db, string_term_tdb_data(key),
+ parent_subkey_scanner, &state);
if (state.scanned) {
result = state.found;
@@ -1281,8 +1282,8 @@ static bool scan_parent_subkeys(const char *parent, const char *name)
if (!create_sorted_subkeys(path, key)) {
goto fail;
}
- res = regdb->parse_record(regdb, string_term_tdb_data(key),
- parent_subkey_scanner, &state);
+ res = db->parse_record(db, string_term_tdb_data(key),
+ parent_subkey_scanner, &state);
if ((res == 0) && (state.scanned)) {
result = state.found;
}
@@ -1330,7 +1331,7 @@ static bool regdb_key_exists(const char *key)
ret = (value.dptr != NULL);
} else {
*p = '\0';
- ret = scan_parent_subkeys(path, p+1);
+ ret = scan_parent_subkeys(regdb, path, p+1);
}
done: