s3:registry: add safety check for return value of tdb_unpack to regdb_fetch_keys_inte...
commit3fb7db84d76f15cc218554559c0f498cf00d1f7c
authorMichael Adam <obnox@samba.org>
Mon, 2 Nov 2009 23:47:37 +0000 (3 00:47 +0100)
committerMichael Adam <obnox@samba.org>
Tue, 10 Nov 2009 11:24:51 +0000 (10 12:24 +0100)
tree40c435f73fa748b176c0db958666fae26307eea6
parentbb939dff52c6a032719c1a2e1e4f6c056e9a0466
s3:registry: add safety check for return value of tdb_unpack to regdb_fetch_keys_internal()

Prevents segfaults in some situations.

(For a non existent or empty record, we sometimes rely on the fetch operation
 to return dsize==0 and sometimes we rely on dptr==NULL.)

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
source3/registry/reg_backend_db.c