From bf52e242f53aeaac33eea69fbdfb3477634b90fb Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 22 May 2004 18:49:25 +0000 Subject: r825: - Introduce support for multiple roots (or 'hives') - Clean up rpc backend (possible now that multiple hives are supported) (This used to be commit 8cd1b6bc70510fe576135a66351e9e3ea895c9ff) --- source4/lib/registry/reg_backend_nt4/reg_backend_nt4.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source4/lib/registry/reg_backend_nt4') diff --git a/source4/lib/registry/reg_backend_nt4/reg_backend_nt4.c b/source4/lib/registry/reg_backend_nt4/reg_backend_nt4.c index cb3c284811..255389624e 100644 --- a/source4/lib/registry/reg_backend_nt4/reg_backend_nt4.c +++ b/source4/lib/registry/reg_backend_nt4/reg_backend_nt4.c @@ -1663,8 +1663,9 @@ static WERROR nt_open_registry (REG_HANDLE *h, const char *location, const char return WERR_OK; } -static WERROR nt_get_root_key(REG_HANDLE *h, REG_KEY **key) +static WERROR nt_get_root_key(REG_HANDLE *h, int hive, REG_KEY **key) { + if(hive != 0) return WERR_NO_MORE_ITEMS; return nk_to_key(h, ((REGF *)h->backend_data)->first_key, BLK_SIZE(((REGF *)h->backend_data)->first_key), NULL, key); } @@ -1737,7 +1738,7 @@ static struct registry_ops reg_backend_nt4 = { .name = "nt4", .open_registry = nt_open_registry, .close_registry = nt_close_registry, - .open_root_key = nt_get_root_key, + .get_hive = nt_get_root_key, .num_subkeys = nt_num_subkeys, .num_values = nt_num_values, .get_subkey_by_index = nt_key_by_index, -- cgit