kiss: Fix stdin with su

This commit is contained in:
Dylan Araps 2020-01-30 10:17:45 +02:00
parent 3e86270338
commit 51d9e82230
No known key found for this signature in database
GPG Key ID: 46D62DD9F1DE636E
1 changed files with 2 additions and 1 deletions

3
kiss
View File

@ -55,7 +55,8 @@ as_root() {
elif command -v doas >/dev/null; then
KISS_FORCE="$KISS_FORCE" doas "$@"
else
su -pc "KISS_FORCE=$KISS_FORCE $*"
exec 3<&0
su -pc "KISS_FORCE=$KISS_FORCE $* <&3" </dev/tty
fi
exit