Daniel:

Can you shed a little more light on why this call isn't always needed? In what 
situations is it necessary to call it?

Sent from my iPhone

On Apr 25, 2011, at 8:02 AM, "Floodeenjr, Thomas" 
<[email protected]> wrote:

> Daniel,
> 
> Yes indeed, we seem to be calling xmlCleanupParser() in many places. We will 
> get with our engineering teams to investigate removing this call from our 
> code. I would imagine that they thought at the time that this call was 
> needed, as it appears to have had no ill side effects in the 2.6.x versions 
> of libxml2.
> 
> Thanks,
> -Tom
> 
> 
> Thomas Floodeen, Jr.
> Mentor Graphics BSD
> 720.494.1133
> 
> 
> -----Original Message-----
> From: Daniel Veillard [mailto:[email protected]] 
> Sent: Monday, April 25, 2011 7:48 AM
> To: Floodeenjr, Thomas
> Cc: [email protected]
> Subject: Re: correct version of libxml2
> 
>  Hi Thomas,
> 
> thanks for getting back to me on this issue, and in the proper forum !
> 
> On Mon, Apr 25, 2011 at 01:30:30PM +0000, Floodeenjr, Thomas wrote:
>> Daniel,
>> 
>> I believe you are correct. I found out that our code works with 
>> libxml2-2.7.2, but started to crash in 2.7.3. I traced it down to a small 
>> change in threads.c:921 in 2.7.3:
>> 
>> #elif defined HAVE_PTHREAD_H
>>    if ((libxml_is_threaded)  && (pthread_key_delete != NULL))
>>        pthread_key_delete(globalkey); #endif
>> 
>> If I comment out the pthread_key_delete() call, our crash goes away. For 
>> expediency, I am doing this now. However, we would like to track down why we 
>> are crashing.
> 
>  How did you end up calling xmlCleanupThreads() where that code is done.
> It sounds very likely that you are calling xmlCleanupParser() while still 
> using the library, and well in that case the crash is normal !
>  http://xmlsoft.org/html/libxml-parser.html#xmlCleanupParser
> 
> see the documentation, you should call this function only once libxml2 is not 
> in use anywhere in the application, which those days is very had to assert. 
> Simplest is to just not call it.
> 
> Daniel
> 
>> -----Original Message-----
>> From: Daniel Veillard [mailto:[email protected]]
>> Sent: Sunday, April 24, 2011 8:17 PM
>> To: Floodeenjr, Thomas
>> Cc: Aleksey Sanin; [email protected]
>> Subject: Re: [xmlsec] correct version of libxml2
>> 
>> On Wed, Apr 20, 2011 at 04:40:37PM +0000, Floodeenjr, Thomas wrote:
>>> Aleksey,
>>> 
>>> We are having problems with libxml2 that are not related to xmlsec.
>>> Our xmlsec tests are working fine so far, but some of our core 
>>> libxml2 usage is broken.
>> 
>>  That's the wrong place to report such problems.
>> 2.6.x releases are rather old and 2.6.12 is very old. I fixed a number of 
>> things in libxml2 since then. If you got troubles, it may be due to a misuse 
>> of the library, compilation problems, or possibly a bug but it's impossible 
>> to tell from your report, and this list ain't the right place for it:
>>  http://xmlsoft.org/bugs.html
>> 
>>  In my experience as libxml2 maintainer most of the time when people 
>> report "bugs" appareing in recent libxml2 versions it is that they 
>> relied upon broken behaviour usually not conformant to the 
>> specification. Hiding the problem around by keeping an obsolete 
>> version of the library rather than investigating the problem exposes 
>> the user to risk including security ones. If you are embbeding libxml2 
>> for any shipping product I urge you to actually report the problem and 
>> get it solved instead of hiding this under the carpet by using an 
>> obsolete
>> libxml2 version,
>> 
>>  thanks in advance,
>> 
>> Daniel
>> 
>> -- 
>> Daniel Veillard      | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
>> [email protected]  | Rpmfind RPM search engine http://rpmfind.net/ 
>> http://veillard.com/ | virtualization library  http://libvirt.org/
> 
> -- 
> Daniel Veillard      | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
> [email protected]  | Rpmfind RPM search engine http://rpmfind.net/ 
> http://veillard.com/ | virtualization library  http://libvirt.org/
> _______________________________________________
> xml mailing list, project page  http://xmlsoft.org/
> [email protected]
> http://mail.gnome.org/mailman/listinfo/xml
_______________________________________________
xml mailing list, project page  http://xmlsoft.org/
[email protected]
http://mail.gnome.org/mailman/listinfo/xml

Reply via email to