[Xfce4-commits] <tumbler:master> We need to include unistd.h for the syscall() function.

Jannis Pohlmann noreply at xfce.org
Sat Oct 10 02:44:01 CEST 2009


Updating branch refs/heads/master
         to 3ecd2f795674f29e1e3b59489f50a11a4c20ac6d (commit)
       from 811a1c5aa8e205a2f4b391977d03af6a9197de4d (commit)

commit 3ecd2f795674f29e1e3b59489f50a11a4c20ac6d
Author: Jannis Pohlmann <jannis at xfce.org>
Date:   Sat Oct 10 02:43:13 2009 +0200

    We need to include unistd.h for the syscall() function.

 configure.ac                 |    2 +-
 tumblerd/tumbler-scheduler.c |    5 ++++-
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/configure.ac b/configure.ac
index e17d512..ee69471 100644
--- a/configure.ac
+++ b/configure.ac
@@ -105,7 +105,7 @@ dnl ***************************************
 dnl *** Check for standard header files ***
 dnl ***************************************
 AC_HEADER_STDC()
-AC_CHECK_HEADERS([sched.h linux/sched.h syscall.h])
+AC_CHECK_HEADERS([unistd.h sched.h linux/sched.h syscall.h])
 
 dnl ************************************
 dnl *** Check for standard functions ***
diff --git a/tumblerd/tumbler-scheduler.c b/tumblerd/tumbler-scheduler.c
index 1390515..043462b 100644
--- a/tumblerd/tumbler-scheduler.c
+++ b/tumblerd/tumbler-scheduler.c
@@ -22,6 +22,9 @@
 #include <config.h>
 #endif
 
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
 #ifdef HAVE_SCHED_H
 #include <sched.h>
 #endif
@@ -292,7 +295,7 @@ tumbler_scheduler_request_compare (gconstpointer a,
 static int
 ioprio_set (int which, int who, int ioprio_val)
 {
-#if defined(__NR_ioprio_set) && defined(HAVE_SYSCALL_H)
+#if defined (__NR_ioprio_set) && defined (HAVE_UNISTD_H)
   return syscall (__NR_ioprio_set, which, who, ioprio_val);
 #else
   return 0;



More information about the Xfce4-commits mailing list