fix #220: errno error.

main
Fabien C. Y. Benureau 5 years ago
parent d06c8da29b
commit 246a00671e
No known key found for this signature in database
GPG Key ID: C3FB5E831A249A9A

@ -3,6 +3,7 @@ from __future__ import print_function, unicode_literals
import os import os
import sys import sys
import shlex import shlex
import errno
import locale import locale
import codecs import codecs
import tempfile import tempfile
@ -237,7 +238,7 @@ class InputUI(PrintUI):
try: try:
subprocess.call(cmd) subprocess.call(cmd)
except OSError as e: except OSError as e:
if e.errno == os.errno.ENOENT: if e.errno == errno.ENOENT:
self.error(("Error while calling editor '{}'. The editor may " self.error(("Error while calling editor '{}'. The editor may "
"not be present. You can change the text editor " "not be present. You can change the text editor "
"that pubs uses by setting the $EDITOR environment " "that pubs uses by setting the $EDITOR environment "

Loading…
Cancel
Save