Added 'file://' prefix to parser file names - thanks to Jay Treacy

svn: r1147
This commit is contained in:
Don Allingham 2002-10-25 00:03:09 +00:00
parent aedf532a43
commit 2933ede739
2 changed files with 3 additions and 3 deletions

View File

@ -715,7 +715,7 @@ class GenericFilterList:
try:
parser = make_parser()
parser.setContentHandler(FilterParser(self))
parser.parse(self.file)
parser.parse('file://' + self.file)
except (IOError,OSError,SAXParseException):
pass

View File

@ -1077,11 +1077,11 @@ try:
parser = make_parser()
path = const.template_dir
parser.setContentHandler(TemplateParser(_template_map,path))
parser.parse("%s/templates.xml" % path)
parser.parse("file://%s/templates.xml" % path)
parser = make_parser()
path = os.path.expanduser("~/.gramps/templates")
parser.setContentHandler(TemplateParser(_template_map,path))
parser.parse("%s/templates.xml" % path)
parser.parse("file://%s/templates.xml" % path)
except (IOError,OSError,SAXParseException):
pass