From fbb5a49cf3cb767b0bbc66fa9ee5e2a598cf0aaf Mon Sep 17 00:00:00 2001 From: Erik Ekman Date: Thu, 5 Jun 2014 02:19:57 +0200 Subject: [PATCH] Fix windows build --- src/common.c | 3 +++ src/common.h | 2 ++ 2 files changed, 5 insertions(+) diff --git a/src/common.c b/src/common.c index 6373a30..2715979 100644 --- a/src/common.c +++ b/src/common.c @@ -464,6 +464,7 @@ int recent_seqno(int ourseqno, int gotseqno) return 0; } +#ifndef WINDOWS32 /* Set FD_CLOEXEC flag on file descriptor. * This stops it from being inherited by system() calls. */ @@ -479,3 +480,5 @@ fd_set_close_on_exec(int fd) if (fcntl(fd, F_SETFD, flags) == -1) err(4, "Failed to set fd flags"); } +#endif + diff --git a/src/common.h b/src/common.h index 7b91942..f363ea5 100644 --- a/src/common.h +++ b/src/common.h @@ -136,6 +136,8 @@ void warnx(const char *fmt, ...); int recent_seqno(int , int); +#ifndef WINDOWS32 void fd_set_close_on_exec(int fd); +#endif #endif