summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2014-06-18 14:11:05 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2014-06-18 14:11:05 +0100
commit40bd45fb802366aa013b9089848b67a28bf3b1ee (patch)
tree18e8b65c9ae3b995cc2954091e5584e10971338c
parente52f917a2370026073ed6851161393a69ee94abe (diff)
backlight: Fix compiler error
/usr/include/xorg/os.h around line 579 reads: extern _X_EXPORT char * strndup(const char *str, size_t n); However strndup is already defined by glibc, and this redefine causes a compile error. This gets triggered because backlight.c does: Without first doing: Causing HAVE_STRNDUP to not be defined. Signed-off-by: Hans de Goede <hdegoede@redhat.com>
-rw-r--r--src/backlight.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/backlight.c b/src/backlight.c
index d5b10a07..f0c549e5 100644
--- a/src/backlight.c
+++ b/src/backlight.c
@@ -42,6 +42,8 @@
#include <fcntl.h>
#include <unistd.h>
#include <dirent.h>
+
+#include <xorg-server.h>
#include <xf86.h>
#include <pciaccess.h>