From d15dedd8c99e84018a50130a8ffe5e971b9f7bd4 Mon Sep 17 00:00:00 2001 From: Pranith Kumar K Date: Thu, 26 Mar 2015 21:08:12 +0530 Subject: xlators/lib: Handle NULL 'name' for marker xattrs Change-Id: I18f00b7e92f483673250821c457d1e8be2eef081 BUG: 1200372 Signed-off-by: Pranith Kumar K Reviewed-on: http://review.gluster.org/10015 Tested-by: Gluster Build System Reviewed-by: Aravinda VK Reviewed-by: Vijay Bellur --- xlators/lib/src/libxlator.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'xlators/lib') diff --git a/xlators/lib/src/libxlator.c b/xlators/lib/src/libxlator.c index 30436131b6b..0f703904fab 100644 --- a/xlators/lib/src/libxlator.c +++ b/xlators/lib/src/libxlator.c @@ -458,6 +458,9 @@ cluster_handle_marker_getxattr (call_frame_t *frame, loc_t *loc, if (GF_CLIENT_PID_GSYNCD != frame->root->pid) return -EINVAL; + if (name == NULL) + return -EINVAL; + if (strcmp (GF_XATTR_MARKER_KEY, name) == 0) { type = MARKER_UUID_TYPE; memcpy (gauge, marker_uuid_default_gauge, sizeof (gauge)); -- cgit