aboutsummaryrefslogtreecommitdiffstats
path: root/src/redshift.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/redshift.c')
-rw-r--r--src/redshift.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/redshift.c b/src/redshift.c
index e24423c..9025552 100644
--- a/src/redshift.c
+++ b/src/redshift.c
@@ -30,7 +30,7 @@
#include <locale.h>
#include <errno.h>
-#ifdef HAVE_SIGNAL_H
+#if defined(HAVE_SIGNAL_H) && !defined(__WIN32__)
# include <signal.h>
#endif
@@ -231,7 +231,7 @@ typedef enum {
} program_mode_t;
-#ifdef HAVE_SIGNAL_H
+#if defined(HAVE_SIGNAL_H) && !defined(__WIN32__)
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_SIGNAL_H */
+#else /* ! HAVE_SIGNAL_H || __WIN32__ */
static int exiting = 0;
static int disable = 0;
-#endif /* ! HAVE_SIGNAL_H */
+#endif /* ! HAVE_SIGNAL_H || __WIN32__ */
/* Calculate color temperature for the specified solar elevation. */
@@ -1101,7 +1101,7 @@ main(int argc, char *argv[])
will be exactly 6500K. */
float adjustment_alpha = 0.0;
-#ifdef HAVE_SIGNAL_H
+#if defined(HAVE_SIGNAL_H) && !defined(__WIN32__)
struct sigaction sigact;
sigset_t sigset;
sigemptyset(&sigset);
@@ -1118,7 +1118,7 @@ main(int argc, char *argv[])
sigact.sa_mask = sigset;
sigact.sa_flags = 0;
sigaction(SIGUSR1, &sigact, NULL);
-#endif /* HAVE_SIGNAL_H */
+#endif /* HAVE_SIGNAL_H && ! __WIN32__ */
/* Continously adjust color temperature */
int done = 0;