6590: gramps40 asciidoc.py crashes for at least some reports
svn: r21874
This commit is contained in:
parent
2cb36a7fb4
commit
028c832153
@ -30,6 +30,7 @@
|
|||||||
# python modules
|
# python modules
|
||||||
#
|
#
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
|
from __future__ import unicode_literals
|
||||||
import io
|
import io
|
||||||
import sys
|
import sys
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
@ -158,7 +159,6 @@ class AsciiDoc(BaseDoc,TextDoc):
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
self.f = io.open(self.filename,"w",
|
self.f = io.open(self.filename,"w",
|
||||||
encoding='ascii',
|
|
||||||
errors = 'backslashreplace')
|
errors = 'backslashreplace')
|
||||||
except Exception as msg:
|
except Exception as msg:
|
||||||
errmsg = "%s\n%s" % (_("Could not create %s") % self.filename, msg)
|
errmsg = "%s\n%s" % (_("Could not create %s") % self.filename, msg)
|
||||||
|
Loading…
Reference in New Issue
Block a user