summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src
diff options
context:
space:
mode:
Diffstat (limited to 'libglusterfs/src')
-rw-r--r--libglusterfs/src/compat.h5
-rw-r--r--libglusterfs/src/syscall.c4
-rw-r--r--libglusterfs/src/syscall.h1
3 files changed, 7 insertions, 3 deletions
diff --git a/libglusterfs/src/compat.h b/libglusterfs/src/compat.h
index 81e74f41075..69adfbcd7fe 100644
--- a/libglusterfs/src/compat.h
+++ b/libglusterfs/src/compat.h
@@ -437,7 +437,6 @@ char *dirname_r(char *path);
#endif /* THREAD_UNSAFE_DIRNAME */
int gf_mkostemp (char *tmpl, int suffixlen, int flags);
-#define mkostemp(tmpl, flags) gf_mkostemp(tmpl, 0, flags);
#ifdef HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC
/* Linux, Solaris, Cygwin */
@@ -482,7 +481,9 @@ int gf_mkostemp (char *tmpl, int suffixlen, int flags);
#if defined(__GNUC__) && !defined(RELAX_POISONING)
/* Use run API, see run.h */
-#pragma GCC poison system popen
+#include <stdlib.h> /* system(), mkostemp() */
+#include <stdio.h> /* popen() */
+#pragma GCC poison system mkostemp popen
#endif
int gf_umount_lazy(char *xlname, char *path, int rmdir);
diff --git a/libglusterfs/src/syscall.c b/libglusterfs/src/syscall.c
index d412b4d656d..7e7db9318f9 100644
--- a/libglusterfs/src/syscall.c
+++ b/libglusterfs/src/syscall.c
@@ -8,14 +8,16 @@
cases as published by the Free Software Foundation.
*/
-#include "compat.h"
#include "syscall.h"
+#include "compat.h"
+#include "mem-pool.h"
#include <sys/types.h>
#include <utime.h>
#include <sys/time.h>
#include <fcntl.h>
#include <unistd.h>
+#include <stdarg.h>
int
sys_lstat (const char *path, struct stat *buf)
diff --git a/libglusterfs/src/syscall.h b/libglusterfs/src/syscall.h
index 10b70927415..b549f6a1b3c 100644
--- a/libglusterfs/src/syscall.h
+++ b/libglusterfs/src/syscall.h
@@ -14,6 +14,7 @@
#include <dirent.h>
#include <sys/uio.h>
#include <sys/statvfs.h>
+#include <sys/stat.h>
/* GF follows the Linux XATTR definition, which differs in Darwin. */
#define GF_XATTR_CREATE 0x1 /* set value, fail if attr already exists */