s3: Fix Coverity ID 2319: Uninitialized read
authorVolker Lendecke <vl@samba.org>
Wed, 16 Mar 2011 16:17:47 +0000 (17:17 +0100)
committerVolker Lendecke <vl@samba.org>
Wed, 16 Mar 2011 17:08:51 +0000 (18:08 +0100)
We passed the structure including the uninitialized elements to
dcerpc_winreg_SetValue.

source3/rpc_client/cli_winreg.c

index 5b8635f1e023415ab6c97a914433245f26181d17..67f85738642d77d41192ef8bbc63336c29933336 100644 (file)
@@ -499,7 +499,7 @@ NTSTATUS dcerpc_winreg_set_multi_sz(TALLOC_CTX *mem_ctx,
                                    const char **data,
                                    WERROR *pwerr)
 {
-       struct winreg_String wvalue;
+       struct winreg_String wvalue = { 0, };
        DATA_BLOB blob;
        WERROR result = WERR_OK;
        NTSTATUS status;