diff --git a/gestion/affich_tools.py b/gestion/affich_tools.py index b3df3832..2d1e9bb5 100755 --- a/gestion/affich_tools.py +++ b/gestion/affich_tools.py @@ -10,10 +10,14 @@ Licence : GPLv2 import sys, sre, os, tempfile # Détermination de l'encodage +encoding = None try: from locale import getpreferredencoding encoding = getpreferredencoding() except: + pass + +if not encoding: encoding = sys.stdin.encoding or "ISO-8859-15" # Si aucune locale n'est définie, on se met en ISO-8859-15