Re: [xml] Opening same xml file in two threads at a time using xmlReadfile/xmlParseFile



On Wed, Feb 03, 2010 at 05:38:01PM +0530, Bhadraji D wrote:

   Here I can use mutex to avoid this but it has to wait for lock . I want
to
   open the xml file and parse simultaneouly.
   How can I handle this ,suggest me.

  It's working fine for me, see testThreads.c in libxxml2 sources,
and it does around 20 simultaneous parses of the same resource,
all this 500 times in a loop. This is ipart of the make check tests
Something else is breaking in your case, but you can use that code to
test on your system and fix your code appropriately.

Daniel

-- 
Daniel Veillard      | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
daniel veillard com  | Rpmfind RPM search engine http://rpmfind.net/
http://veillard.com/ | virtualization library  http://libvirt.org/



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