Handle lit files with the ampersand character in the names of constituent files.

This commit is contained in:
Kovid Goyal 2008-01-14 21:41:40 +00:00
parent 88055d3e7b
commit 45903db4c9

View File

@ -1347,6 +1347,8 @@ class HTMLConverter(object):
elif tagname == 'img': elif tagname == 'img':
if tag.has_key('src'): if tag.has_key('src'):
path = munge_paths(self.target_prefix, tag['src'])[0] path = munge_paths(self.target_prefix, tag['src'])[0]
if not os.path.exists(path):
path = path.replace('&', '%26') # convertlit replaces & with %26
if os.access(path, os.R_OK) and os.path.isfile(path): if os.access(path, os.R_OK) and os.path.isfile(path):
width, height = None, None width, height = None, None
try: try: