]> granicus.if.org Git - ejabberd/commitdiff
Improve TTY code to work on more operating systems (thanks to Jan Koum)
authorBadlop <badlop@process-one.net>
Fri, 12 Feb 2010 21:11:15 +0000 (22:11 +0100)
committerBadlop <badlop@process-one.net>
Fri, 12 Feb 2010 21:11:15 +0000 (22:11 +0100)
src/ejabberdctl.template

index d425a18c970416b490e44f529c5aa2621c54aa4b..5567a90af49d22fcab15dc6deb2c93eccc2b1ae3 100644 (file)
@@ -169,7 +169,7 @@ debug ()
        read foo
     fi
     echo ""
-    TTY=`tty | cut -f4 -d'/'`
+    TTY=`tty | sed -e  's/.*\///g'`
     $EXEC_CMD "$ERL \
       $NAME debug-${TTY}-${ERLANG_NODE} \
       -remsh $ERLANG_NODE \