From 43695cfba3bcbb53d7127128e37a724862f65017 Mon Sep 17 00:00:00 2001 From: Krutika Dhananjay Date: Tue, 3 Jan 2017 20:13:40 +0530 Subject: api: Fix incorrect strcmp() during fs initialisation Just chanced upon this while reading graph switch code in libgfapi. Change-Id: Ie62b410c22e6d0768a24187c5d587b6d3fc996bf Signed-off-by: Krutika Dhananjay Reviewed-on: https://review.gluster.org/16319 Smoke: Gluster Build System NetBSD-regression: NetBSD Build System Reviewed-by: Amar Tumballi CentOS-regression: Gluster Build System Reviewed-by: Vijay Bellur --- api/src/gfapi-messages.h | 2 +- api/src/glfs-mgmt.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/api/src/gfapi-messages.h b/api/src/gfapi-messages.h index 6e131b5a295..b4ecefbeb56 100644 --- a/api/src/gfapi-messages.h +++ b/api/src/gfapi-messages.h @@ -58,7 +58,7 @@ #define API_MSG_FSMUTEX_UNLOCK_FAILED (GLFS_GFAPI_BASE + 10) #define API_MSG_INODE_REFRESH_FAILED (GLFS_GFAPI_BASE + 11) #define API_MSG_GRAPH_CONSTRUCT_FAILED (GLFS_GFAPI_BASE + 12) -#define API_MSG_FUSE_XLATOR_ERROR (GLFS_GFAPI_BASE + 13) +#define API_MSG_API_XLATOR_ERROR (GLFS_GFAPI_BASE + 13) #define API_MSG_XDR_PAYLOAD_FAILED (GLFS_GFAPI_BASE + 14) #define API_MSG_GET_VOLINFO_CBK_FAILED (GLFS_GFAPI_BASE + 15) #define API_MSG_FETCH_VOLUUID_FAILED (GLFS_GFAPI_BASE + 16) diff --git a/api/src/glfs-mgmt.c b/api/src/glfs-mgmt.c index 3c8b3b0102f..1bfebcf2d03 100644 --- a/api/src/glfs-mgmt.c +++ b/api/src/glfs-mgmt.c @@ -61,10 +61,10 @@ glfs_process_volfp (struct glfs *fs, FILE *fp) } for (trav = graph->first; trav; trav = trav->next) { - if (strcmp (trav->type, "mount/fuse") == 0) { + if (strcmp (trav->type, "mount/api") == 0) { gf_msg ("glfs", GF_LOG_ERROR, EINVAL, - API_MSG_FUSE_XLATOR_ERROR, - "fuse xlator cannot be specified " + API_MSG_API_XLATOR_ERROR, + "api master xlator cannot be specified " "in volume file"); goto out; } -- cgit