Commit d879da15 authored by Egil Moeller's avatar Egil Moeller

Bugfix to handle big files

parent f6e1f482
......@@ -84,7 +84,7 @@ class KML(object):
def from_string(self, xml_string):
""" create a KML object from a xml string"""
element = etree.XML(xml_string)
element = etree.fromstring(xml_string, parser=etree.XMLParser(huge_tree=True))
if element.tag.endswith('kml'):
ns = element.tag.rstrip('kml')
documents = element.findall('%sDocument' % ns)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment