summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-hooks.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-hooks.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-hooks.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-hooks.c b/xlators/mgmt/glusterd/src/glusterd-hooks.c
index 4db5460c798..45a5912a1eb 100644
--- a/xlators/mgmt/glusterd/src/glusterd-hooks.c
+++ b/xlators/mgmt/glusterd/src/glusterd-hooks.c
@@ -15,6 +15,7 @@
#include "logging.h"
#include "run.h"
#include "defaults.h"
+#include "syscall.h"
#include "compat.h"
#include "compat-errno.h"
#include "glusterd.h"
@@ -343,7 +344,7 @@ glusterd_hooks_run_hooks (char *hooks_path, glusterd_op_t op, dict_t *op_ctx,
goto out;
}
- hookdir = opendir (hooks_path);
+ hookdir = sys_opendir (hooks_path);
if (!hookdir) {
ret = -1;
gf_msg (this->name, GF_LOG_ERROR, errno,
@@ -420,7 +421,7 @@ out:
}
if (hookdir)
- closedir (hookdir);
+ sys_closedir (hookdir);
return ret;
}