From bbd0bda9c2213215efeb13f5fe527d2409dc79b2 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Mon, 3 Mar 2014 13:49:46 +0100 Subject: smbd: Fix an uninitialized memory read This might be the reason for a few flaky builds. Signed-off-by: Volker Lendecke Reviewed-by: Michael Adam Autobuild-User(master): Michael Adam Autobuild-Date(master): Mon Mar 3 16:30:53 CET 2014 on sn-devel-104 --- source3/locking/brlock.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'source3/locking') diff --git a/source3/locking/brlock.c b/source3/locking/brlock.c index e6c89490ae3..ac22ba44d9a 100644 --- a/source3/locking/brlock.c +++ b/source3/locking/brlock.c @@ -2085,6 +2085,8 @@ static void brl_get_locks_readonly_parser(TDB_DATA key, TDB_DATA data, if ((data.dsize % sizeof(struct lock_struct)) == 1) { br_lock->have_read_oplocks = (data.dptr[data.dsize-1] == 1); + } else { + br_lock->have_read_oplocks = false; } DEBUG(10, ("Got %d bytes, have_read_oplocks: %s\n", (int)data.dsize, -- cgit