[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#514922: xinit: startx should pass error code from xinit



Hrm, after looking at the source package.. This patch would probably be more
useful.
>From a51fc675ebffae0e55dd65f2453b4b7615882f43 Mon Sep 17 00:00:00 2001
From: Andres Salomon <dilinger@debian.org>
Date: Wed, 11 Feb 2009 17:02:05 -0500
Subject: [PATCH] startx: use the same exit code that xinit exits with

Signed-off-by: Andres Salomon <dilinger@debian.org>
---
 startx.cpp |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/startx.cpp b/startx.cpp
index 9266341..753f470 100644
--- a/startx.cpp
+++ b/startx.cpp
@@ -303,6 +303,7 @@ fi
 #else
 XINIT $client $clientargs -- $server $display $serverargs
 #endif
+retval=$?
 
 if [ x"$enable_xauth" = x1 ] ; then
     if [ x"$removelist" != x ]; then
@@ -330,3 +331,6 @@ screenrestore
 #if defined(sun)
 kbd_mode -a
 #endif
+
+exit $retval
+
-- 
1.5.6.5


Reply to: