From 6884e6a5b0cabdce39005470f4bcd0d960cfc956 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mathieu=20B=C3=A9rard?= Date: Thu, 9 Feb 2017 14:05:32 +0100 Subject: The smart scheduler is not optional. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Backported from X.org: commit 9f9268821b13038556fbc029df54ab0e9b2aa77f Author: Mathieu BĂ©rard Date: Mon Aug 11 13:52:38 2008 -0400 The smart scheduler is not optional. Backported-to-NX-by: Mike Gabriel --- nx-X11/programs/Xserver/hw/nxagent/Display.c | 35 ---------------------------- 1 file changed, 35 deletions(-) (limited to 'nx-X11/programs/Xserver/hw/nxagent/Display.c') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.c b/nx-X11/programs/Xserver/hw/nxagent/Display.c index d8e6aa7e3..eaee84855 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.c @@ -597,8 +597,6 @@ Display *nxagentInternalOpenDisplay(char *display) int result; - #ifdef SMART_SCHEDULE - /* * Stop the smart schedule timer since * it uses SIGALRM as we do. @@ -606,8 +604,6 @@ Display *nxagentInternalOpenDisplay(char *display) nxagentStopTimer(); - #endif - /* * Install the handler rejecting a possible * loopback connection. @@ -678,16 +674,12 @@ static void nxagentDisplayBlockHandler(Display *display, int reason) * for the remote display. */ - #ifdef SMART_SCHEDULE - #ifdef DEBUG fprintf(stderr, "nxagentDisplayBlockHandler: BLOCK! Stopping the smart schedule timer.\n"); #endif nxagentStopTimer(); - #endif - if (reason == NXBlockRead) { #ifdef DEBUG @@ -702,13 +694,9 @@ static void nxagentDisplayBlockHandler(Display *display, int reason) nxagentBlocking = 1; - #ifdef SMART_SCHEDULE - if (SmartScheduleDisable == 1) { - #endif - /* * Let the dispatch attend the next * client. @@ -723,12 +711,8 @@ static void nxagentDisplayBlockHandler(Display *display, int reason) nxagentDispatch.in = nxagentBytesIn; nxagentDispatch.out = nxagentBytesOut; - #ifdef SMART_SCHEDULE - } - #endif - /* * Give a chance to the next client. */ @@ -1022,12 +1006,8 @@ void nxagentInstallSignalHandlers() * Reset the SIGALRM to the default. */ - #ifdef SMART_SCHEDULE - nxagentStopTimer(); - #endif - newAction.sa_handler = SIG_DFL; sigfillset(&newAction.sa_mask); @@ -1040,8 +1020,6 @@ void nxagentInstallSignalHandlers() FatalError("Can't set the handler for alarm signal."); } - #ifdef SMART_SCHEDULE - /* * Let the smart schedule set the SIGALRM * handler again. @@ -1049,8 +1027,6 @@ void nxagentInstallSignalHandlers() nxagentInitTimer(); - #endif - /* * Install our own handler for the SIGHUP. */ @@ -1146,12 +1122,8 @@ void nxagentResetSignalHandlers() * Reset the SIGALRM to the default. */ - #ifdef SMART_SCHEDULE - nxagentStopTimer(); - #endif - newAction.sa_handler = SIG_DFL; sigfillset(&newAction.sa_mask); @@ -1164,8 +1136,6 @@ void nxagentResetSignalHandlers() FatalError("Can't set the handler for alarm signal."); } - #ifdef SMART_SCHEDULE - /* * Let the smart schedule set the SIGALRM * handler again. @@ -1173,7 +1143,6 @@ void nxagentResetSignalHandlers() nxagentInitTimer(); - #endif } void nxagentOpenDisplay(int argc, char *argv[]) @@ -2969,16 +2938,12 @@ void nxagentWaitDisplay() * Disable the smart scheduler's interrupts. */ - #ifdef SMART_SCHEDULE - #ifdef DEBUG fprintf(stderr, "nxagentWaitDisplay: Stopping the smart schedule timer.\n"); #endif nxagentStopTimer(); - #endif - if (nxagentDisplay != NULL) { #ifdef TEST -- cgit v1.2.3