From d9553b2bbe06fba0b209218ffed9465edd79b4d2 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Tue, 13 Mar 2012 09:29:39 +1000 Subject: Xext: pass the counter into block/wakeup handlers No functional changes, currently unused. Preparation work, we don't need a global variable if we can pass the counters around anyway. Signed-off-by: Peter Hutterer Reviewed-by: Jeremy Huddleston Reviewed-by: Jamey Sharp Reviewed-by: James Jones --- Xext/sync.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Xext') diff --git a/Xext/sync.c b/Xext/sync.c index a692b6e29..94972ead9 100644 --- a/Xext/sync.c +++ b/Xext/sync.c @@ -2603,7 +2603,7 @@ IdleTimeQueryValue(pointer pCounter, CARD64 * pValue_return) } static void -IdleTimeBlockHandler(pointer env, struct timeval **wt, pointer LastSelectMask) +IdleTimeBlockHandler(pointer pCounter, struct timeval **wt, pointer LastSelectMask) { SyncCounter *counter = IdleTimeCounter; XSyncValue *less = pIdleTimeValueLess, @@ -2678,7 +2678,7 @@ IdleTimeBlockHandler(pointer env, struct timeval **wt, pointer LastSelectMask) } static void -IdleTimeWakeupHandler(pointer env, int rc, pointer LastSelectMask) +IdleTimeWakeupHandler(pointer pCounter, int rc, pointer LastSelectMask) { SyncCounter *counter = IdleTimeCounter; XSyncValue idle; @@ -2706,11 +2706,11 @@ IdleTimeBracketValues(pointer pCounter, CARD64 * pbracket_less, if (registered && !pbracket_less && !pbracket_greater) { RemoveBlockAndWakeupHandlers(IdleTimeBlockHandler, - IdleTimeWakeupHandler, NULL); + IdleTimeWakeupHandler, pCounter); } else if (!registered && (pbracket_less || pbracket_greater)) { RegisterBlockAndWakeupHandlers(IdleTimeBlockHandler, - IdleTimeWakeupHandler, NULL); + IdleTimeWakeupHandler, pCounter); } pIdleTimeValueGreater = pbracket_greater; -- cgit v1.2.3