mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-04-26 15:09:07 +03:00
1. Setting entity loader does not increment the refcount on the Python object passed in. This works only if the object is not deleted. For example, the following code results in segmentation fault in Python interpreter when attempting to process any document: [[[ def register_entity_loader(): def entity_loader(URL, ID, ctxt): ... libxml2.setEntityLoader(entity_loader register_entity_loader() ]]] 2. setEntityLoader() does not verify if the passed object is callable. If it is not, current implementation attempts to call it anyway and failing that, silently moves on to default entity loader. Attached patch makes setEntityLoader raise ValueError exception if non-callable object is passed. 3. In debug mode, pythonExternalEntityLoader() outputs the result object to stderr, while the messages before and after the object (description + newline) go to stdout. Attached patch makes them all go to stdout.
Module libxml2-python ===================== This is the libxml2 python module, providing access to the libxml2 and libxslt (if available) libraries. For general informationss on those XML and XSLT libraries check their web pages at : http://xmlsoft.org/ and http://xmlsoft.org/XSLT/ The latest version of the sources for this module and the associated libraries can be found at: ftp://xmlsoft.org/ Binaries packages of the libxml2 and libxslt libraries can be found either on the FTP site for Linux, from external sources linked from the web pages, or as part of your set of packages provided with your operating system. NOTE: this module distribution is not the primary distribution of the libxml2 and libxslt Python binding code, but as the Python way of packaging those for non-Linux systems. The main sources are the libxml2 and libxslt tar.gz found on the site. One side effect is that the official RPM packages for those modules are not generated from the libxml2-python distributions but as part of the normal RPM packaging of those two libraries. The RPM packages can be found at: http://rpmfind.net/linux/rpm2html/search.php?query=libxml2-python http://rpmfind.net/linux/rpm2html/search.php?query=libxslt-python Daniel Veillard