gdm r6625 - in trunk: . data



Author: halfline
Date: Mon Dec  8 16:09:50 2008
New Revision: 6625
URL: http://svn.gnome.org/viewvc/gdm?rev=6625&view=rev

Log:
2008-12-08  Ray Strode  <rstrode redhat com>

	* data/{PreSession,PostSession}.in:
	gut functions, since they were redundant
	with what we do in code now (bug 563550)

	* data/Init.in:
	apply patch from Pacho Ramos to quote
	shell conditionals better (bug 563550).


Modified:
   trunk/ChangeLog
   trunk/data/Init.in
   trunk/data/PostSession.in
   trunk/data/PreSession.in

Modified: trunk/data/Init.in
==============================================================================
--- trunk/data/Init.in	(original)
+++ trunk/data/Init.in	Mon Dec  8 16:09:50 2008
@@ -32,8 +32,8 @@
 sysmodmap=/etc/X11/Xmodmap
 
 XMODMAP=`gdmwhich xmodmap`
-if [ x$XMODMAP != x ] ; then
-  if [ x$GDM_PARENT_DISPLAY = x ]; then
+if [ "x$XMODMAP" != "x" ] ; then
+  if [ "x$GDM_PARENT_DISPLAY" = "x" ]; then
     if [ -f $sysmodmap ]; then
       $XMODMAP $sysmodmap
     fi
@@ -47,7 +47,7 @@
 
   UNAME=`gdmwhich uname`
   PROCESSOR=`$UNAME -p`
-  if [ x$PROCESSOR = xsparc ]; then
+  if [ "x$PROCESSOR" = "xsparc" ]; then
     if $XMODMAP | /usr/bin/grep mod4 | /usr/bin/grep Alt > /dev/null 2>/dev/null
     then
       $XMODMAP -e "clear Mod1" \
@@ -61,7 +61,7 @@
 fi
 
 SETXKBMAP=`gdmwhich setxkbmap`
-if [ x$SETXKBMAP != x ] ; then
+if [ "x$SETXKBMAP" != "x" ] ; then
   # FIXME: is this all right?  Is this completely on crack?
   # What this does is move the xkb configuration from the GDM_PARENT_DISPLAY
   # FIXME: This should be done in code.  Or there must be an easier way ...

Modified: trunk/data/PostSession.in
==============================================================================
--- trunk/data/PostSession.in	(original)
+++ trunk/data/PostSession.in	Mon Dec  8 16:09:50 2008
@@ -1,27 +1,3 @@
 #!/bin/sh
 
-PATH="@X_PATH@:$PATH:/bin:/usr/bin"
-OLD_IFS=$IFS
-
-gdmwhich () {
-  COMMAND="$1"
-  OUTPUT=
-  IFS=:
-  for dir in $PATH
-  do
-    if test -x "$dir/$COMMAND" ; then
-      if test "x$OUTPUT" = "x" ; then
-        OUTPUT="$dir/$COMMAND"
-      fi
-    fi
-  done
-  IFS=$OLD_IFS
-  echo "$OUTPUT"
-}
-
-SESSREG=`gdmwhich sessreg`
-if [ "x$SESSREG" != "x" ] ; then
-	"$SESSREG" -d -w /var/log/wtmp -u /var/run/utmp -x "$X_SERVERS" -h "$REMOTE_HOST" -l "$DISPLAY" "$USER"
-fi
-
 exit 0

Modified: trunk/data/PreSession.in
==============================================================================
--- trunk/data/PreSession.in	(original)
+++ trunk/data/PreSession.in	Mon Dec  8 16:09:50 2008
@@ -7,34 +7,3 @@
 # Note that output goes into the .xsession-errors file for easy debugging
 #
 PATH="@X_PATH@:$PATH:/bin:/usr/bin"
-OLD_IFS=$IFS
-
-gdmwhich () {
-  COMMAND="$1"
-  OUTPUT=
-  IFS=:
-  for dir in $PATH
-  do
-    if test -x "$dir/$COMMAND" ; then
-      if test "x$OUTPUT" = "x" ; then
-        OUTPUT="$dir/$COMMAND"
-      fi
-    fi
-  done
-  IFS=$OLD_IFS
-  echo "$OUTPUT"
-}
-
-SESSREG=`gdmwhich sessreg`
-if [ "x$SESSREG" != "x" ] ; then
-	# some output for easy debugging
-	echo "$0: Registering your session with wtmp and utmp"
-	echo "$0: running: $SESSREG -a -w /var/log/wtmp -u /var/run/utmp -x \"$X_SERVERS\" -h \"$REMOTE_HOST\" -l \"$DISPLAY\" \"$USER\""
-
-	exec "$SESSREG" -a -w /var/log/wtmp -u /var/run/utmp -x "$X_SERVERS" -h "$REMOTE_HOST" -l "$DISPLAY" "$USER"
-	# this is not reached
-fi
-
-# some output for easy debugging
-echo "$0: could not find the sessreg utility, cannot update wtmp and utmp"
-exit 0



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