X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/13725744fde97fd9e511adb118ee2c9389116243..0314302e9cbe851f05b6f4567f2c1978a38471e3:/testsuite/chown.test diff --git a/testsuite/chown.test b/testsuite/chown.test index 755ffdf8..90af529e 100644 --- a/testsuite/chown.test +++ b/testsuite/chown.test @@ -15,6 +15,16 @@ set -x +case `id -u` in +'') ;; # If "id" failed, try to continue... +0) ;; +*) if [ -f /usr/bin/fakeroot ]; then + echo "Let's try re-running the script under fakeroot..." + exec /usr/bin/fakeroot /bin/sh "$0" + fi + ;; +esac + # Build some hardlinks mkdir "$fromdir"