summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaghavendra Talur <rtalur@redhat.com>2014-02-13 12:31:58 +0530
committerAnand Avati <avati@redhat.com>2014-02-19 19:25:34 -0800
commit9e0ec224148e1d3e0406eb5aa4479f3dca0d597b (patch)
tree64803ce19a8d935bb5f97fa50ad2a851202877e6
parentff0cd7c4e326d848d5fa6591c7cc8ce54711d2d7 (diff)
protocol/auth: Fix a possible double free.
Assign NULL to addr_cpy to avoid double free. Fix for coverity CID: 1124891 Change-Id: I0cd6721f066170190d8b5441ecdbc1704ed5e75b BUG: 789278 Signed-off-by: Raghavendra Talur <rtalur@redhat.com> Reviewed-on: http://review.gluster.org/6993 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
-rw-r--r--xlators/protocol/auth/addr/src/addr.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/xlators/protocol/auth/addr/src/addr.c b/xlators/protocol/auth/addr/src/addr.c
index 64e8d0fc6a6..181d091bd49 100644
--- a/xlators/protocol/auth/addr/src/addr.c
+++ b/xlators/protocol/auth/addr/src/addr.c
@@ -181,6 +181,7 @@ gf_auth (dict_t *input_params, dict_t *config_params)
addr_str = strtok_r (NULL, ADDR_DELIMITER, &tmp);
}
GF_FREE (addr_cpy);
+ addr_cpy = NULL;
}
if (allow_addr) {