zookeeper-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ph...@apache.org
Subject zookeeper git commit: ZOOKEEPER-2890: Local automatic variable is left uninitialized and then freed.
Date Tue, 10 Oct 2017 18:49:15 GMT
Repository: zookeeper
Updated Branches:
  refs/heads/branch-3.4 25df0aa8d -> 948766de3


ZOOKEEPER-2890: Local automatic variable is left uninitialized and then freed.

Fixes https://issues.apache.org/jira/browse/ZOOKEEPER-2890

Author: xoiss <xoiss@ubuntu>

Reviewers: Patrick Hunt <phunt@apache.org>

Closes #359 from xoiss/branch-3.4-bugfix-zookeeper-2890

Change-Id: Ib3d132fc812a62b720967a888aff28edb7f3bdf1


Project: http://git-wip-us.apache.org/repos/asf/zookeeper/repo
Commit: http://git-wip-us.apache.org/repos/asf/zookeeper/commit/948766de
Tree: http://git-wip-us.apache.org/repos/asf/zookeeper/tree/948766de
Diff: http://git-wip-us.apache.org/repos/asf/zookeeper/diff/948766de

Branch: refs/heads/branch-3.4
Commit: 948766de31eb955d62e661b7c55b74aa64434c77
Parents: 25df0aa
Author: xoiss <xoiss@ubuntu>
Authored: Tue Oct 10 11:41:21 2017 -0700
Committer: Patrick Hunt <phunt@apache.org>
Committed: Tue Oct 10 11:41:21 2017 -0700

----------------------------------------------------------------------
 src/c/src/zookeeper.c | 1 +
 1 file changed, 1 insertion(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/zookeeper/blob/948766de/src/c/src/zookeeper.c
----------------------------------------------------------------------
diff --git a/src/c/src/zookeeper.c b/src/c/src/zookeeper.c
index f8d42ff..c087864 100644
--- a/src/c/src/zookeeper.c
+++ b/src/c/src/zookeeper.c
@@ -2108,6 +2108,7 @@ static void deserialize_response(int type, int xid, int failed, int
rc, completi
             cptr->c.string_result(rc, 0, cptr->data);
         } else {
             struct CreateResponse res;
+            memset(&res, 0, sizeof(res));
             deserialize_CreateResponse(ia, "reply", &res);
             cptr->c.string_result(rc, res.path, cptr->data);
             deallocate_CreateResponse(&res);


Mime
View raw message