]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: Ensure initialized vars in do_lock
authorVolker Lendecke <vl@samba.org>
Mon, 1 Jul 2019 12:19:16 +0000 (14:19 +0200)
committerJeremy Allison <jra@samba.org>
Tue, 2 Jul 2019 17:01:27 +0000 (17:01 +0000)
brl_lock does not initialize these variables in all cases

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/locking/locking.c

index aa4d17e04d1732527b4389a58f88f05d2f410ee8..c186312f93fa54480a75ea8ff194ece7398cf2f0 100644 (file)
@@ -243,8 +243,8 @@ struct byte_range_lock *do_lock(struct messaging_context *msg_ctx,
                        uint64_t *psmblctx)
 {
        struct byte_range_lock *br_lck = NULL;
-       struct server_id blocker_pid;
-       uint64_t blocker_smblctx;
+       struct server_id blocker_pid = { 0 };
+       uint64_t blocker_smblctx = 0;
 
        /* silently return ok on print files as we don't do locking there */
        if (fsp->print_file) {