From 3038a87edce31ad2895431f7cfdc96a33fc70e02 Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Sat, 30 Mar 2013 10:59:06 -0700 Subject: Check for configure's HAVE_UNISTD_H instead of X_NOT_POSIX Drops fallback prototype of sleep() for non-POSIX, non-Windows systems Signed-off-by: Alan Coopersmith --- AuLock.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/AuLock.c b/AuLock.c index 3ae7596..b9859f1 100644 --- a/AuLock.c +++ b/AuLock.c @@ -33,15 +33,12 @@ in this Software without prior written authorization from The Open Group. #include #include #define Time_t time_t -#ifndef X_NOT_POSIX -#include -#else -#ifndef WIN32 -extern unsigned sleep (); -#else -#include -#define link rename +#ifdef HAVE_UNISTD_H +# include #endif +#ifdef WIN32 +# include +# define link rename #endif int -- cgit v1.2.3