blob: e17e8e66dd72f70b2c48e11fc4e46a629cca5a94 [file] [log] [blame]
Matt Kraai14b7c5d2001-12-11 16:43:48 +00001touch foo
2chmod a-r foo
Eric Andersen650fe632004-04-06 11:10:30 +00003set +e
Denis Vlasenkob9ad75f2008-03-28 17:49:31 +00004if test `id -u` = 0; then
5 # run as user with nonzero uid
6 setuidgid 1 busybox cp foo bar
7else
8 busybox cp foo bar
9fi
Eric Andersen650fe632004-04-06 11:10:30 +000010set -e
Matt Kraai14b7c5d2001-12-11 16:43:48 +000011test ! -f bar