[xmlsec] xmlInitParser() crashes when timer functions are used like CreateTimerQueueTimer()

Daniel Veillard veillard at redhat.com
Fri Jan 5 03:06:54 PST 2007


On Fri, Jan 05, 2007 at 11:22:15AM +0530, Yeshwanth C wrote:
> It appears that if the thread is switched to some other thread, these calls
> to libxml2 all fail.
> Because when I ran the same code in a loop and checked the thread id, for
> successful runs, the thread ids were all the same.
> Could you tell me some way how to switch the thread back to the original
> thread before calling these methods? or suggest some other solution?

  Read !
    http://xmlsoft.org/threads.html
xmlInitParser() must be called *only once* *in the main thread* !
So please forget about calling it repeatedly on a timer loop on
different threads, it's completely wrong... and has nothing to do
with xmlsec, just the fact you didn't read the documentation, so
stop sending tons of mails about this on the list.

Daniel

-- 
Red Hat Virtualization group http://redhat.com/virtualization/
Daniel Veillard      | virtualization library  http://libvirt.org/
veillard at redhat.com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine  http://rpmfind.net/



More information about the xmlsec mailing list