diff options
author | Albert Lee <> | 2011-07-04 14:20:51 +0200 |
---|---|---|
committer | Jon Lund Steffensen <jonlst@gmail.com> | 2011-07-04 14:20:51 +0200 |
commit | 4b05bbee41da71244d4b630357643b73e371530b (patch) | |
tree | f887f5809ab6a9e48e7410fa74049c8620fe63cd | |
parent | Install Ubuntu icons as option (--enable-ubuntu). (Francesco Marella) (diff) | |
download | redshift-ng-4b05bbee41da71244d4b630357643b73e371530b.tar.gz redshift-ng-4b05bbee41da71244d4b630357643b73e371530b.tar.bz2 redshift-ng-4b05bbee41da71244d4b630357643b73e371530b.tar.xz |
Use signal.h instead of sys/signal.h for POSIX compliance.
-rw-r--r-- | configure.ac | 2 | ||||
-rw-r--r-- | src/redshift.c | 14 |
2 files changed, 8 insertions, 8 deletions
diff --git a/configure.ac b/configure.ac index b6868e9..ae5874e 100644 --- a/configure.ac +++ b/configure.ac @@ -190,7 +190,7 @@ AS_IF([test "x$enable_ubuntu" != xno], [ AM_CONDITIONAL([ENABLE_UBUNTU], [test "x$enable_ubuntu" != xno]) # Checks for header files. -AC_CHECK_HEADERS([locale.h stdint.h stdlib.h string.h unistd.h sys/signal.h]) +AC_CHECK_HEADERS([locale.h stdint.h stdlib.h string.h unistd.h signal.h]) # Checks for typedefs, structures, and compiler characteristics. AC_TYPE_UINT16_T diff --git a/src/redshift.c b/src/redshift.c index 2273d7c..af154b8 100644 --- a/src/redshift.c +++ b/src/redshift.c @@ -30,8 +30,8 @@ #include <locale.h> #include <errno.h> -#ifdef HAVE_SYS_SIGNAL_H -# include <sys/signal.h> +#ifdef HAVE_SIGNAL_H +# include <signal.h> #endif #ifdef ENABLE_NLS @@ -231,7 +231,7 @@ typedef enum { } program_mode_t; -#ifdef HAVE_SYS_SIGNAL_H +#ifdef HAVE_SIGNAL_H static volatile sig_atomic_t exiting = 0; static volatile sig_atomic_t disable = 0; @@ -250,12 +250,12 @@ sigdisable(int signo) disable = 1; } -#else /* ! HAVE_SYS_SIGNAL_H */ +#else /* ! HAVE_SIGNAL_H */ static int exiting = 0; static int disable = 0; -#endif /* ! HAVE_SYS_SIGNAL_H */ +#endif /* ! HAVE_SIGNAL_H */ /* Calculate color temperature for the specified solar elevation. */ @@ -1095,7 +1095,7 @@ main(int argc, char *argv[]) will be exactly 6500K. */ float adjustment_alpha = 0.0; -#ifdef HAVE_SYS_SIGNAL_H +#ifdef HAVE_SIGNAL_H struct sigaction sigact; sigset_t sigset; sigemptyset(&sigset); @@ -1112,7 +1112,7 @@ main(int argc, char *argv[]) sigact.sa_mask = sigset; sigact.sa_flags = 0; sigaction(SIGUSR1, &sigact, NULL); -#endif /* HAVE_SYS_SIGNAL_H */ +#endif /* HAVE_SIGNAL_H */ /* Continously adjust color temperature */ int done = 0; |