I just committed the liblouisxml.c module with a revamped processXmlDocument routine. Everything having to do with xml documents as such or libxml2 is in that function. It seems to handle errors fine. The cleanup should also work. At least there is no segmentation fault. John -- John J. boyer; President, Chief Software Developer Abilitiessoft, Inc. http://www.abilitiessoft.com Madison, Wisconsin USA Developing software for people with disabilities For a description of the software and to download it go to http://www.jjb-software.com