]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: Fix Coverity ID 242715 Uninitialized scalar variable
authorVolker Lendecke <vl@samba.org>
Wed, 9 May 2012 08:56:54 +0000 (10:56 +0200)
committerVolker Lendecke <vl@samba.org>
Thu, 10 May 2012 07:11:58 +0000 (09:11 +0200)
In an error path we are closing hive_hnd without opening it

source3/rpc_client/cli_winreg_spoolss.c

index 4aa1f28cb96bb31d75903625cdf5b2268d66acb1..7bd5033dcb44d4a23a7b39f26bd46f2154602939 100644 (file)
@@ -2907,7 +2907,7 @@ WERROR winreg_printer_setform1(TALLOC_CTX *mem_ctx,
                               struct spoolss_AddFormInfo1 *form)
 {
        uint32_t access_mask = SEC_FLAG_MAXIMUM_ALLOWED;
-       struct policy_handle hive_hnd;
+       struct policy_handle hive_hnd = { 0, };
        struct policy_handle key_hnd = { 0, };
        struct winreg_String wvalue = { 0, };
        DATA_BLOB blob;