diff options
Diffstat (limited to 'apps/xhost/xhost.c')
-rw-r--r-- | apps/xhost/xhost.c | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/apps/xhost/xhost.c b/apps/xhost/xhost.c index 08f7c7969..6f803c002 100644 --- a/apps/xhost/xhost.c +++ b/apps/xhost/xhost.c @@ -163,6 +163,16 @@ static volatile int nameserver_timedout; static char *ProgramName; +#ifdef WIN32 +#define alarm(arg) + +void sethostent(int x) +{} + +void endhostent() +{} +#endif + #ifdef NEEDSOCKETS static int XFamily(int af) @@ -787,7 +797,7 @@ get_hostname(XHostAddress *ha) sa.sa_handler = nameserver_lost; sa.sa_flags = 0; /* don't restart syscalls */ sigaction(SIGALRM, &sa, NULL); -#else +#elif !defined(WIN32) signal(SIGALRM, nameserver_lost); #endif alarm(NAMESERVER_TIMEOUT); @@ -965,12 +975,3 @@ local_xerror(Display *dpy, XErrorEvent *rep) XmuPrintDefaultErrorMessage (dpy, rep, stderr); return 0; } - -#ifdef __CYGWIN__ -void sethostent(int x) -{} - -void endhostent() -{} -#endif - |