registry: fetch regdb_fetch_keys() when a key exists but not its subkey-record.
authorMichael Adam <obnox@samba.org>
Tue, 8 Jul 2008 15:10:01 +0000 (17:10 +0200)
committerMichael Adam <obnox@samba.org>
Tue, 8 Jul 2008 15:10:01 +0000 (17:10 +0200)
commitf329aaf0452cc9bbad9fb6f67dac00bf8d1ef128
tree131bc244325280d29836baab161c8e5fe637dbee
parent22735ee14a244dbda768c26dbe83a1b2aa3c03ec
registry: fetch regdb_fetch_keys() when a key exists but not its subkey-record.

According to the new policy a key (that is not a base key) exists,
iff it exists in the subkey list of its parent key.

Usually this subkeylist is present, but in a transaction-less
dbwrap backend (ctdb), a failing write can leave an "incomplete"
key without its own subkeylist-record. (Otherwise such an
incomplete key can be generated with e.g. tdbtool.)
For such a key net registry enumerate (e.g.) would fail.
This commit fixes this behaviour of regdb_fetch_keys().

Michael
source/registry/reg_backend_db.c