From a915739887477b28d924ecc8417ee107d125bd6c Mon Sep 17 00:00:00 2001 From: marha Date: Sun, 6 Sep 2009 18:48:27 +0000 Subject: Switched to xorg-server-1.6.99.900.tar.gz --- xorg-server/os/WaitFor.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'xorg-server/os/WaitFor.c') diff --git a/xorg-server/os/WaitFor.c b/xorg-server/os/WaitFor.c index d6dd99553..dfe85e515 100644 --- a/xorg-server/os/WaitFor.c +++ b/xorg-server/os/WaitFor.c @@ -92,6 +92,8 @@ SOFTWARE. #define GetErrno() errno #endif +/* like ffs, but uses fd_mask instead of int as argument, so it works + when fd_mask is longer than an int, such as common 64-bit platforms */ /* modifications by raphael */ int mffs(fd_mask mask) @@ -109,8 +111,7 @@ mffs(fd_mask mask) } #ifdef DPMSExtension -#define DPMS_SERVER -#include +#include #endif struct _OsTimerRec { @@ -336,7 +337,7 @@ WaitForSomething(int *pClientsReady) { int client_priority, client_index; - curclient = ffs (clientsReadable.fds_bits[i]) - 1; + curclient = mffs (clientsReadable.fds_bits[i]) - 1; client_index = /* raphael: modified */ ConnectionTranslation[curclient + (i * (sizeof(fd_mask) * 8))]; #else @@ -421,7 +422,7 @@ DoTimer(OsTimerPtr timer, CARD32 now, OsTimerPtr *prev) TimerSet(timer, 0, newTime, timer->callback, timer->arg); } -_X_EXPORT OsTimerPtr +OsTimerPtr TimerSet(OsTimerPtr timer, int flags, CARD32 millis, OsTimerCallback func, pointer arg) { @@ -430,7 +431,7 @@ TimerSet(OsTimerPtr timer, int flags, CARD32 millis, if (!timer) { - timer = (OsTimerPtr)xalloc(sizeof(struct _OsTimerRec)); + timer = xalloc(sizeof(struct _OsTimerRec)); if (!timer) return NULL; } @@ -492,7 +493,7 @@ TimerForce(OsTimerPtr timer) } -_X_EXPORT void +void TimerCancel(OsTimerPtr timer) { OsTimerPtr *prev; @@ -509,7 +510,7 @@ TimerCancel(OsTimerPtr timer) } } -_X_EXPORT void +void TimerFree(OsTimerPtr timer) { if (!timer) -- cgit v1.2.3