[crans] On cumule les erreurs

This commit is contained in:
Vincent Le Gallic 2013-09-12 10:33:07 +02:00
parent 6532f805ad
commit 5ce1dd11c2
9 changed files with 20 additions and 47 deletions

View file

@ -5,6 +5,8 @@ if [ ! -e /usr/scripts/var/encodage_scripts/$UID ]; then
touch /usr/scripts/var/encodage_scripts/$UID
else
# Si le script sort avec une erreur, on purge les locks deads
LANG=fr_FR.UTF-8 sudo -u respbats /usr/scripts/gestion/gest_crans.py "$@" \
|| LANG=fr_FR.UTF-8 sudo -u respbats /usr/scripts/gestion/ldap_crans.py --zombielock
LANG=fr_FR.UTF-8 sudo -u respbats /usr/scripts/gestion/gest_crans.py "$@"
trucmuche=$?
[ $trucmuche -eq 0 ] || LANG=fr_FR.UTF-8 sudo -u respbats /usr/scripts/gestion/ldap_crans.py --zombielock
exit $(($trucmuche + $?))
fi;