summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorotto <otto@openbsd.org>2010-04-26 09:04:15 +0000
committerotto <otto@openbsd.org>2010-04-26 09:04:15 +0000
commit44ab491afd48df480c141a23527c75c87d6934c7 (patch)
tree95fd87b5dcdc628989fb28694814f26b18a732d6
parentFix some memory leaks on config reload failure and move one particular (diff)
downloadwireguard-openbsd-44ab491afd48df480c141a23527c75c87d6934c7.tar.xz
wireguard-openbsd-44ab491afd48df480c141a23527c75c87d6934c7.zip
don't throw away exit status of various commands; ok sthen@ dcoppa@ halex@
-rw-r--r--etc/ksh.kshrc14
1 files changed, 13 insertions, 1 deletions
diff --git a/etc/ksh.kshrc b/etc/ksh.kshrc
index 2acb6299754..10f30367484 100644
--- a/etc/ksh.kshrc
+++ b/etc/ksh.kshrc
@@ -1,5 +1,5 @@
:
-# $OpenBSD: ksh.kshrc,v 1.14 2009/08/07 09:05:24 martynas Exp $
+# $OpenBSD: ksh.kshrc,v 1.15 2010/04/26 09:04:15 otto Exp $
#
# NAME:
# ksh.kshrc - global initialization for ksh
@@ -102,27 +102,39 @@ case "$-" in
wcd () { \cd "$@" && eval stripe; }
wssh ()
{
+ local rc
"ssh" "$@"
+ rc=$?
eval istripe
eval stripe
+ return $rc
}
wtelnet ()
{
+ local rc
"telnet" "$@"
+ rc=$?
eval istripe
eval stripe
+ return $rc
}
wrlogin ()
{
+ local rc
"rlogin" "$@"
+ rc=$?
eval istripe
eval stripe
+ return $rc
}
wsu ()
{
+ local rc
"su" "$@"
+ rc=$?
eval istripe
eval stripe
+ return $rc
}
alias su=wsu
alias cd=wcd