]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: Fix the build with clang
authorVolker Lendecke <vl@samba.org>
Wed, 31 Jul 2019 08:42:24 +0000 (10:42 +0200)
committerJeremy Allison <jra@samba.org>
Tue, 6 Aug 2019 21:49:28 +0000 (21:49 +0000)
clang correctly complains that "close_fsp" is used uninitialized if
"get_posix_fsp" fails and we end up in "goto out;".

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

index 6ecd467a321497daca70e6293b1c2af55d5f4c0a..41f8dac13f0615043bca4321e068505595b3ed17 100644 (file)
@@ -4918,7 +4918,7 @@ static NTSTATUS smb_query_posix_acl(connection_struct *conn,
        unsigned int size_needed = 0;
        NTSTATUS status;
        bool ok;
-       bool close_fsp;
+       bool close_fsp = false;
 
        /*
         * Ensure we always operate on a file descriptor, not just