summaryrefslogtreecommitdiffstats
path: root/xlators/mount
diff options
context:
space:
mode:
authorPranith Kumar K <pkarampu@redhat.com>2016-01-06 14:30:08 +0530
committerPranith Kumar Karampuri <pkarampu@redhat.com>2016-07-25 23:47:33 -0700
commitd2bd17e5a53d0ffa375df1a5ad957556be2f2b83 (patch)
tree872633e25252817ee332d0b64a92cd64eba7464b /xlators/mount
parent558a45fa527b01ec81904150532a8b661c06ae8a (diff)
dict: Don't expose get_new_dict/dict_destroy
get_new_dict/dict_destroy is causing confusion where, dict_new/dict_destroy or get_new_dict/dict_unref are used instead of dict_new/dict_unref. Change-Id: I4cc69f5b6711d720823395e20fd624a0c6c1168c BUG: 1296043 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/13183 Smoke: Gluster Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.org> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Krutika Dhananjay <kdhananj@redhat.com>
Diffstat (limited to 'xlators/mount')
-rw-r--r--xlators/mount/fuse/src/fuse-bridge.c3
-rw-r--r--xlators/mount/fuse/src/fuse-bridge.h2
2 files changed, 1 insertions, 4 deletions
diff --git a/xlators/mount/fuse/src/fuse-bridge.c b/xlators/mount/fuse/src/fuse-bridge.c
index eead33fbd55..a79f7497acf 100644
--- a/xlators/mount/fuse/src/fuse-bridge.c
+++ b/xlators/mount/fuse/src/fuse-bridge.c
@@ -3282,7 +3282,7 @@ fuse_setxattr (xlator_t *this, fuse_in_header_t *finh, void *msg)
fuse_resolve_inode_init (state, &state->resolve, finh->nodeid);
- state->xattr = get_new_dict ();
+ state->xattr = dict_new ();
if (!state->xattr) {
gf_log ("glusterfs-fuse", GF_LOG_ERROR,
"%"PRIu64": SETXATTR dict allocation failed",
@@ -3312,7 +3312,6 @@ fuse_setxattr (xlator_t *this, fuse_in_header_t *finh, void *msg)
}
dict_set (state->xattr, newkey,
data_from_dynptr ((void *)dict_value, fsi->size));
- dict_ref (state->xattr);
state->flags = fsi->flags;
state->name = newkey;
diff --git a/xlators/mount/fuse/src/fuse-bridge.h b/xlators/mount/fuse/src/fuse-bridge.h
index 40bd17ba6e6..e4075c83f2c 100644
--- a/xlators/mount/fuse/src/fuse-bridge.h
+++ b/xlators/mount/fuse/src/fuse-bridge.h
@@ -257,7 +257,6 @@ typedef struct fuse_graph_switch_args fuse_graph_switch_args_t;
GF_LOG_WARNING, \
"%s Failed adding umask"\
" to request", op); \
- dict_destroy (state->xdata); \
send_fuse_err (this, finh, ENOMEM); \
free_fuse_state (state); \
return; \
@@ -269,7 +268,6 @@ typedef struct fuse_graph_switch_args fuse_graph_switch_args_t;
GF_LOG_WARNING, \
"%s Failed adding mode " \
"to request", op); \
- dict_destroy (state->xdata); \
send_fuse_err (this, finh, ENOMEM); \
free_fuse_state (state); \
return; \