From 96dbf4dcb1e04571363422a97649fc929b35beb8 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Sun, 22 Jan 2012 00:20:07 -0600 Subject: Second part of prior commit --- .../patches/kubuntu_9921_kdm_bulletproof_x.diff | 64 ---------------------- .../patches/kubuntu_9921_tdm_bulletproof_x.diff | 64 ++++++++++++++++++++++ 2 files changed, 64 insertions(+), 64 deletions(-) delete mode 100644 ubuntu/lucid_automake/kdebase/debian/patches/kubuntu_9921_kdm_bulletproof_x.diff create mode 100644 ubuntu/lucid_automake/kdebase/debian/patches/kubuntu_9921_tdm_bulletproof_x.diff (limited to 'ubuntu/lucid_automake/kdebase/debian/patches') diff --git a/ubuntu/lucid_automake/kdebase/debian/patches/kubuntu_9921_kdm_bulletproof_x.diff b/ubuntu/lucid_automake/kdebase/debian/patches/kubuntu_9921_kdm_bulletproof_x.diff deleted file mode 100644 index f2584303c..000000000 --- a/ubuntu/lucid_automake/kdebase/debian/patches/kubuntu_9921_kdm_bulletproof_x.diff +++ /dev/null @@ -1,64 +0,0 @@ ---- kdebase-3.5.8/tdm/backend/dm.c 2008-02-13 23:59:17.000000000 +0200 -+++ kdebase-3.5.8/tdm/backend/dm.c 2008-02-14 11:22:41.000000000 +0200 -@@ -996,9 +996,14 @@ ReapChildren( void ) - /* don't kill again */ - break; - case running: -- if (startingServer == d && d->serverStatus != ignore) { -- if (d->serverStatus == starting && waitCode( status ) != 47) -- LogError( "X server died during startup\n" ); -+ LogError("X server terminated: [%d, %d, %d]\n", -+ (startingServer == d), -+ (d->serverStatus), -+ (waitCode(status))); -+ -+ if (startingServer == d /*&& d->serverStatus != ignore*/) { -+ if (/*d->serverStatus == starting &&*/ waitCode( status ) != 47) -+ LogError( "X server died during startup\n" ); - StartServerFailed(); - break; - } ---- kdebase-3.5.8/tdm/backend/server.c 2008-02-13 23:59:17.000000000 +0200 -+++ kdebase-3.5.8/tdm/backend/server.c 2008-02-14 11:41:20.000000000 +0200 -@@ -48,6 +48,10 @@ from the copyright holder. - struct display *startingServer; - time_t serverTimeout = TO_INF; - -+#define SERVER_ATTEMPTS 3 -+ -+char* failsafeXServer[] = {"/etc/gdm/failsafeXServer", 0}; -+ - char ** - PrepServerArgv( struct display *d, const char *args ) - { -@@ -128,6 +132,7 @@ StartServer( struct display *d ) - { - startingServer = d; - d->startTries = 0; -+ d->serverAttempts = SERVER_ATTEMPTS; - StartServerOnce(); - } - -@@ -150,6 +155,7 @@ void - StartServerSuccess() - { - struct display *d = startingServer; -+ LogError("StartServerSucces\n"); - d->serverStatus = ignore; - serverTimeout = TO_INF; - Debug( "X server ready, starting session\n" ); -@@ -161,9 +167,14 @@ StartServerFailed() - { - struct display *d = startingServer; - if (!d->serverAttempts || d->startTries < d->serverAttempts) { -+ LogError("Failed to start X server. Starting failsafe X server.\n"); -+ -+ runAndWait(failsafeXServer, 0); -+ - d->serverStatus = pausing; - serverTimeout = d->openDelay + now; - } else { -+ LogError("StartServerFailed\n"); - d->serverStatus = ignore; - serverTimeout = TO_INF; - startingServer = 0; diff --git a/ubuntu/lucid_automake/kdebase/debian/patches/kubuntu_9921_tdm_bulletproof_x.diff b/ubuntu/lucid_automake/kdebase/debian/patches/kubuntu_9921_tdm_bulletproof_x.diff new file mode 100644 index 000000000..f2584303c --- /dev/null +++ b/ubuntu/lucid_automake/kdebase/debian/patches/kubuntu_9921_tdm_bulletproof_x.diff @@ -0,0 +1,64 @@ +--- kdebase-3.5.8/tdm/backend/dm.c 2008-02-13 23:59:17.000000000 +0200 ++++ kdebase-3.5.8/tdm/backend/dm.c 2008-02-14 11:22:41.000000000 +0200 +@@ -996,9 +996,14 @@ ReapChildren( void ) + /* don't kill again */ + break; + case running: +- if (startingServer == d && d->serverStatus != ignore) { +- if (d->serverStatus == starting && waitCode( status ) != 47) +- LogError( "X server died during startup\n" ); ++ LogError("X server terminated: [%d, %d, %d]\n", ++ (startingServer == d), ++ (d->serverStatus), ++ (waitCode(status))); ++ ++ if (startingServer == d /*&& d->serverStatus != ignore*/) { ++ if (/*d->serverStatus == starting &&*/ waitCode( status ) != 47) ++ LogError( "X server died during startup\n" ); + StartServerFailed(); + break; + } +--- kdebase-3.5.8/tdm/backend/server.c 2008-02-13 23:59:17.000000000 +0200 ++++ kdebase-3.5.8/tdm/backend/server.c 2008-02-14 11:41:20.000000000 +0200 +@@ -48,6 +48,10 @@ from the copyright holder. + struct display *startingServer; + time_t serverTimeout = TO_INF; + ++#define SERVER_ATTEMPTS 3 ++ ++char* failsafeXServer[] = {"/etc/gdm/failsafeXServer", 0}; ++ + char ** + PrepServerArgv( struct display *d, const char *args ) + { +@@ -128,6 +132,7 @@ StartServer( struct display *d ) + { + startingServer = d; + d->startTries = 0; ++ d->serverAttempts = SERVER_ATTEMPTS; + StartServerOnce(); + } + +@@ -150,6 +155,7 @@ void + StartServerSuccess() + { + struct display *d = startingServer; ++ LogError("StartServerSucces\n"); + d->serverStatus = ignore; + serverTimeout = TO_INF; + Debug( "X server ready, starting session\n" ); +@@ -161,9 +167,14 @@ StartServerFailed() + { + struct display *d = startingServer; + if (!d->serverAttempts || d->startTries < d->serverAttempts) { ++ LogError("Failed to start X server. Starting failsafe X server.\n"); ++ ++ runAndWait(failsafeXServer, 0); ++ + d->serverStatus = pausing; + serverTimeout = d->openDelay + now; + } else { ++ LogError("StartServerFailed\n"); + d->serverStatus = ignore; + serverTimeout = TO_INF; + startingServer = 0; -- cgit v1.2.1