git.samba.org
/
kai
/
samba-autobuild
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d7b9e0d
)
dbwrap: intialize state.status in dbwrap_fetch_int32()
author
Stefan Metzmacher
<metze@samba.org>
Fri, 22 Jun 2012 13:08:22 +0000
(15:08 +0200)
committer
Stefan Metzmacher
<metze@samba.org>
Fri, 22 Jun 2012 13:16:53 +0000
(15:16 +0200)
This might not be needed, but it makes it more clear that
we won't use uninitialized memory, it the callback was not triggered.
metze
lib/dbwrap/dbwrap_util.c
patch
|
blob
|
history
diff --git
a/lib/dbwrap/dbwrap_util.c
b/lib/dbwrap/dbwrap_util.c
index b1efae7221372fd4791af0263b69351955d2da9b..84520707829f61d45baa4138a1193969d0ba61a6 100644
(file)
--- a/
lib/dbwrap/dbwrap_util.c
+++ b/
lib/dbwrap/dbwrap_util.c
@@
-54,6
+54,8
@@
NTSTATUS dbwrap_fetch_int32(struct db_context *db, TDB_DATA key,
return NT_STATUS_INVALID_PARAMETER;
}
+ state.status = NT_STATUS_INTERNAL_ERROR;
+
dbwrap_parse_record(db, key, dbwrap_fetch_int32_parser, &state);
if (NT_STATUS_IS_OK(state.status)) {