summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src/dict.c
diff options
context:
space:
mode:
authorVijay Bellur <vbellur@redhat.com>2019-02-27 16:02:43 -0800
committerPranith Kumar Karampuri <pkarampu@redhat.com>2019-04-12 13:08:28 +0000
commitc261eb6c1fa41b6a0eadabbb3a2f64dc194ec254 (patch)
tree93eb38d3e003c998a53844cc7a0081d1a9cf9b40 /libglusterfs/src/dict.c
parent0e1223491e964096384edfae5032ed0d50d028ad (diff)
Replace memdup() with gf_memdup()
memdup() and gf_memdup() have the same implementation. Removed one API as the presence of both can be confusing. Change-Id: I562130c668457e13e4288e592792872d2e49887e updates: bz#1193929 Signed-off-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'libglusterfs/src/dict.c')
-rw-r--r--libglusterfs/src/dict.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libglusterfs/src/dict.c b/libglusterfs/src/dict.c
index 6b63b8f0e8b..2374ab032d1 100644
--- a/libglusterfs/src/dict.c
+++ b/libglusterfs/src/dict.c
@@ -306,7 +306,7 @@ data_copy(data_t *old)
newdata->len = old->len;
if (old->data) {
- newdata->data = memdup(old->data, old->len);
+ newdata->data = gf_memdup(old->data, old->len);
if (!newdata->data)
goto err_out;
}
@@ -3139,7 +3139,7 @@ dict_unserialize(char *orig_buf, int32_t size, dict_t **fill)
goto out;
}
value->len = vallen;
- value->data = memdup(buf, vallen);
+ value->data = gf_memdup(buf, vallen);
value->data_type = GF_DATA_TYPE_STR_OLD;
value->is_static = _gf_false;
buf += vallen;