Stupid fix: abort after 3 attempts missing

This commit is contained in:
BoySka 2011-10-28 20:18:34 +02:00 committed by Jaromil
parent 18febabbe5
commit 7a16c7f187

View File

@ -295,7 +295,7 @@ check_priv() {
sudok=false sudok=false
sudo -n ${TOMBEXEC} &> /dev/null sudo -n ${TOMBEXEC} &> /dev/null
if [ $? != 0 ]; then # if not then ask a password if [ $? != 0 ]; then # if not then ask a password
for imnotused in 1 2 3; do for i in 1 2 3; do
cat <<EOF | pinentry 2>/dev/null | awk '/^D / { sub(/^D /, ""); print }' | sudo -S -v cat <<EOF | pinentry 2>/dev/null | awk '/^D / { sub(/^D /, ""); print }' | sudo -S -v
OPTION ttyname=$TTY OPTION ttyname=$TTY
OPTION lc-ctype=$LANG OPTION lc-ctype=$LANG
@ -308,6 +308,7 @@ EOF
break break
fi fi
if [[ $i == 3 ]]; then if [[ $i == 3 ]]; then
exit 16
fi fi
done done
fi fi