[liblouis-liblouisxml] Re: Getting libxml2 to use lou_logPrint for its error messages.

  • From: "John J. Boyer" <john.boyer@xxxxxxxxxxxxxxxxx>
  • To: liblouis-liblouisxml@xxxxxxxxxxxxx
  • Date: Wed, 13 Jan 2010 09:00:44 -0600

Christian,

I tried to get that example from the Web and got the message "The 
Requested fragment doesn't exist." If you have it please send it as an 
attachment. Thanks for your work. This will be a real improvement.

John

On Wed, Jan 13, 2010 at 03:29:17PM +0100, Christian Egli wrote:
> Hi
> 
> "John J. Boyer" <john.boyer@xxxxxxxxxxxxxxxx> writes:
> > If you uncomment the code that assigns the callback and then try an xml 
> > file with errors you will get a segmentation fault. I'm not sure I'm 
> > using the right function assignment or the right parameters. 
> 
> I seem to have found a solution for the problem where libxml2 wasn't
> using lou_logPrint. Check the latest commit in liblouisxml
> (http://code.google.com/p/liblouisxml/source/detail?r=206). I used
> http://github.com/martine/LogJam/blob/master/src/tools.c#L284 as an
> example on how to achieve this. However as you see from the example what
> is missing is the clean up part. I do not free the context (
> xmlFreeParserCtxt(ctxt);) and I do not set the old error handler
> (apparently through initGenericErrorDefaultFunc(NULL);). I tried to do
> this but I got a segmentation fault.
> 
> Maybe this helps for further explorations
> 
> Thanks
> Christian
> -- 
> Christian Egli
> Swiss Library for the Blind, Visually Impaired and Print Disabled
> Grubenstrasse 12, CH-8045 Z??rich, Switzerland
> For a description of the software and to download it go to
> http://www.jjb-software.com

-- 
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

Other related posts: