Commit eb0ffe7a authored by Sören Tempel's avatar Sören Tempel Committed by Natanael Copa

abuild: use id instead of whoami

Furthermore compare the UID instead of the username.
parent d5013a39
......@@ -2148,7 +2148,7 @@ done
shift $(( $OPTIND - 1 ))
# check so we are not root
if [ "$(whoami)" = "root" ] && [ -z "$FAKEROOTKEY" ]; then
if [ $(id -u) -eq 0 ] && [ -z "$FAKEROOTKEY" ]; then
[ -z "$forceroot" ] && die "Do not run abuild as root"
FAKEROOT=
fi
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment