mirror of
https://github.com/samba-team/samba.git
synced 2025-09-11 09:44:19 +03:00
lib:util: Check return value of tdb_parse_record()
This makes covscan happy. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
committed by
Jeremy Allison
parent
e8e1a74da3
commit
e25af2bc4f
@@ -142,8 +142,11 @@ static int fetch_int32_parser(TDB_DATA key, TDB_DATA data, void *private_data)
|
|||||||
|
|
||||||
static int32_t tdb_fetch_int32_byblob(struct tdb_context *tdb, TDB_DATA key)
|
static int32_t tdb_fetch_int32_byblob(struct tdb_context *tdb, TDB_DATA key)
|
||||||
{
|
{
|
||||||
int v = -1;
|
int32_t v = -1;
|
||||||
tdb_parse_record(tdb, key, fetch_int32_parser, &v);
|
int32_t ret = tdb_parse_record(tdb, key, fetch_int32_parser, &v);
|
||||||
|
if (ret == -1) {
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
return v;
|
return v;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user