aboutsummaryrefslogtreecommitdiffstats
path: root/runtests.sh
diff options
context:
space:
mode:
authorWayne Davison <wayned@samba.org>2005-02-20 16:27:10 +0000
committerWayne Davison <wayned@samba.org>2005-02-20 16:27:10 +0000
commit19cb6106d25ea13cc394637206147c8fb51ffdff (patch)
treea51c69afaf665b72367027574623dd846968fdde /runtests.sh
parentcd6bececc1576edf3d463d8ed30a8e867ca7f43b (diff)
downloadandroid_external_rsync-19cb6106d25ea13cc394637206147c8fb51ffdff.tar.gz
android_external_rsync-19cb6106d25ea13cc394637206147c8fb51ffdff.tar.bz2
android_external_rsync-19cb6106d25ea13cc394637206147c8fb51ffdff.zip
Improved the testuser-setting code to try to get it to work
under solaris.
Diffstat (limited to 'runtests.sh')
-rwxr-xr-xruntests.sh8
1 files changed, 7 insertions, 1 deletions
diff --git a/runtests.sh b/runtests.sh
index f5655e79..7b0654df 100755
--- a/runtests.sh
+++ b/runtests.sh
@@ -142,7 +142,13 @@ echo "$0 running in `pwd`"
echo " rsync_bin=$rsync_bin"
echo " srcdir=$srcdir"
-testuser=`id -un || whoami || echo UNKNOWN`
+if test -e /usr/bin/whoami; then
+ testuser=`/usr/bin/whoami`
+elif test -e /usr/ucb/whoami; then
+ testuser=`/usr/ucb/whoami`
+else
+ testuser=`id -un || whoami || echo UNKNOWN`
+fi
echo " testuser=$testuser"
echo " os=`uname -a`"