Re: [xml] libxml and threads



On Wed, Feb 23, 2005 at 12:26:32PM +0100, Massimo Cafaro wrote:
May be there is a little misunderstanding here. 
I said in my first email that it is entirely my fault the problem I am 
experiencing because I am new to the use of libxml2. 
I did not say that libxml2 code leaks memory. I want to make clear 
again that its is my responsibility, not yours. 

  As I said, since that specific part of the code use malloc()
directly and not the wrappers, it is possible to have a leak there
that went unnoticed, though it is unlikely. Hence my request for
a reproduceable test case in case you still get the problem after
following the suggestions.

I can only say thanks for your suggestions. Unfortunately I did not 
find a detailed documentation on the web site. This is actually a pity 

   That is not normal, really, if you go to the web site:
     http://xmlsoft.org/
     in the left menu, the link in bold "Developer Menu" should really
     raise your attention, then once there
     http://xmlsoft.org/docs.html
     the item "Thread safety" should really be obvious too
     http://xmlsoft.org/threads.html
     and you get to the page with the advices

  Do you remember what step you missed to get there ?

since I firmly believe that libxml2 is a great achievement, but its 
complexity makes it difficult to use it correctly ( I have been 
developing unix apps for almost 20 years, including of course threaded 
apps, so I now exactly what kind of problems can occur). 

   So you should not be surprized that a library which maintains state
need to have a initialization routine called in the main thread before
further processing.

Thanks again, 

   No problem.

Daniel

-- 
Daniel Veillard      | Red Hat Desktop team http://redhat.com/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]