diff options
Diffstat (limited to 'libglusterfs')
-rw-r--r-- | libglusterfs/src/common-utils.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libglusterfs/src/common-utils.c b/libglusterfs/src/common-utils.c index eefb5f159fe..ad3d308d92a 100644 --- a/libglusterfs/src/common-utils.c +++ b/libglusterfs/src/common-utils.c @@ -4066,7 +4066,6 @@ gf_is_service_running(char *pidfile, int *pid) ret = lockf(fno, F_TEST, 0); if (ret == -1) { running = _gf_true; - goto out; } ret = fscanf(file, "%d", pid); @@ -4074,6 +4073,8 @@ gf_is_service_running(char *pidfile, int *pid) gf_msg("", GF_LOG_ERROR, errno, LG_MSG_FILE_OP_FAILED, "Unable to read pidfile: %s", pidfile); *pid = -1; + running = _gf_false; + goto out; } running = gf_is_pid_running(*pid); |