[xml] Deadlock in catalog.c?



Hi,

I'm stuck on what looks like a deadlock in libxml2.

My application calls xmlInitializeCatalog() and xmlLoadCatalog(...) (which returns 0) in the main thread. Then another thread is launched in which I do XML validation with DTDs. These work fine until a XML file refers to a DTD that has to be looked up in the catalog file that I loaded with xmlLoadCatalog(...): then the thread blocks when trying to lock xmlCatalogMutex (catalog.c, line 1416 in the function xmlFetchXMLCatalogFile). The strange thing is that there are no other threads doing any locking (except for the thread created by libxml2 that waits in xmlGlobalStateCleanupHelper).

I noticed that if I do the same XML validation on the main thread, it works fine, and after that it works on the other thread as well.


Regards,

--
 Mark
 _________________________________________
 When you get lemons, you make lemonade.
 When you get hardware, you make software.




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