Fix problem with parsing erroneous options that contain UTF-8.

This commit is contained in:
Sei Lisa 2017-01-11 01:36:24 +01:00
parent 3afd961cf7
commit 26b49b0807

View file

@ -383,7 +383,7 @@ def main(argv):
if chgfix[1:] not in validoptions:
Usage(argv[0], 'optimizer-options')
sys.stderr.write(u"\nError: Unrecognized"
u" optimizer option: %s\n" % chg)
u" optimizer option: %s\n" % chg.decode('utf8'))
return 1
if chgfix[0] == '-':
options.discard(chgfix[1:])