]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
libcls/nbt: clang: Fix 'initialization value is never read'
authorNoel Power <noel.power@suse.com>
Tue, 9 Jul 2019 14:45:52 +0000 (14:45 +0000)
committerGary Lockyer <gary@samba.org>
Wed, 24 Jul 2019 21:33:21 +0000 (21:33 +0000)
Fixes:

libcli/nbt/nbtsocket.c:65:27: warning: Value stored to 'req' during its initialization is never read <--[clang]
        struct nbt_name_request *req = nbtsock->send_queue;
                                 ^~~   ~~~~~~~~~~~~~~~~~~~
1 warning generated.

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
libcli/nbt/nbtsocket.c

index 33d53fba9939c88eb6c3327793ea47acad4ab822..38a2192fbcdacbb094032d4af2dd1440557c0bd3 100644 (file)
@@ -62,7 +62,7 @@ static int nbt_name_request_destructor(struct nbt_name_request *req)
 */
 static void nbt_name_socket_send(struct nbt_name_socket *nbtsock)
 {
-       struct nbt_name_request *req = nbtsock->send_queue;
+       struct nbt_name_request *req;
        TALLOC_CTX *tmp_ctx = talloc_new(nbtsock);
        NTSTATUS status;