[Lxml-checkins] r47900 - lxml/trunk/src/lxml

scoder at codespeak.net scoder at codespeak.net
Thu Oct 25 11:10:31 CEST 2007


Author: scoder
Date: Thu Oct 25 11:10:31 2007
New Revision: 47900

Modified:
   lxml/trunk/src/lxml/schematron.pxi
Log:
raise memory error in schematron where appropriate

Modified: lxml/trunk/src/lxml/schematron.pxi
==============================================================================
--- lxml/trunk/src/lxml/schematron.pxi	(original)
+++ lxml/trunk/src/lxml/schematron.pxi	Thu Oct 25 11:10:31 2007
@@ -101,9 +101,8 @@
             raise SchematronParseError, "No tree or file given"
 
         if parser_ctxt is NULL:
-            if c_doc is not NULL:
-                tree.xmlFreeDoc(c_doc)
-            raise SchematronParseError, "Document is not parsable as Schematron"
+            python.PyErr_NoMemory()
+
         self._c_schema = schematron.xmlSchematronParse(parser_ctxt)
 
         schematron.xmlSchematronFreeParserCtxt(parser_ctxt)


More information about the lxml-checkins mailing list