From 2099cc875a4d20ab1bb12b1c33da16c95968e202 Mon Sep 17 00:00:00 2001 From: "Kaleb S. KEITHLEY" Date: Thu, 1 Oct 2015 16:28:58 -0400 Subject: core: use syscall wrappers instead of direct syscalls - libglusterfs various xlators and other components are invoking system calls directly instead of using the libglusterfs/syscall.[ch] wrappers. If not using the system call wrappers there should be a comment in the source explaining why the wrapper isn't used. Change-Id: Ieeca2d36adbc884e4cfa0026dba40df70310d40b BUG: 1267967 Signed-off-by: Kaleb S. KEITHLEY Reviewed-on: http://review.gluster.org/12275 Tested-by: NetBSD Build System Tested-by: Gluster Build System Reviewed-by: Jeff Darcy --- libglusterfs/src/compat.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'libglusterfs/src/compat.c') diff --git a/libglusterfs/src/compat.c b/libglusterfs/src/compat.c index e50f27bff90..621ff5f54c9 100644 --- a/libglusterfs/src/compat.c +++ b/libglusterfs/src/compat.c @@ -24,6 +24,7 @@ #include "common-utils.h" #include "iatt.h" #include "inode.h" +#include "syscall.h" #include "run.h" #include "libglusterfs-messages.h" @@ -570,7 +571,7 @@ gf_umount_lazy (char *xlname, char *path, int rmdir_flag) #ifdef GF_LINUX_HOST_OS if (!ret && rmdir_flag) { - ret = rmdir (path); + ret = sys_rmdir (path); if (ret) gf_msg (xlname, GF_LOG_WARNING, errno, LG_MSG_DIR_OP_FAILED, "rmdir %s", path); -- cgit