summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2012-05-09 10:56:54 +0200
committerVolker Lendecke <vl@samba.org>2012-05-10 09:11:57 +0200
commit2a03d9e42c71bc164936d3e46e1240494ca33bd5 (patch)
tree99739fdc7ee8fe9c1e10de47c38e9078fbe122b5
parent74ca9cc957cfd0f9a6c33b6c9cb8d7822ff7e7ff (diff)
downloadsamba-2a03d9e42c71bc164936d3e46e1240494ca33bd5.tar.gz
samba-2a03d9e42c71bc164936d3e46e1240494ca33bd5.tar.bz2
samba-2a03d9e42c71bc164936d3e46e1240494ca33bd5.zip
s3: Fix Coverity ID 242718 Uninitialized scalar variable
In an error path we are closing user_pol without opening it
-rw-r--r--source3/rpcclient/cmd_samr.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source3/rpcclient/cmd_samr.c b/source3/rpcclient/cmd_samr.c
index 196e40fd33..ebc13c3334 100644
--- a/source3/rpcclient/cmd_samr.c
+++ b/source3/rpcclient/cmd_samr.c
@@ -2703,7 +2703,8 @@ static NTSTATUS cmd_samr_chgpasswd(struct rpc_pipe_client *cli,
TALLOC_CTX *mem_ctx,
int argc, const char **argv)
{
- struct policy_handle connect_pol, domain_pol, user_pol;
+ struct policy_handle connect_pol, domain_pol;
+ struct policy_handle user_pol = { 0, };
NTSTATUS status, result;
const char *user, *oldpass, *newpass;
uint32 access_mask = MAXIMUM_ALLOWED_ACCESS;