Re: [xml] windows multi-threading

2005-02-24 Thread Daniel Veillard
On Thu, Feb 24, 2005 at 12:25:55PM -0500, Rob Richards wrote: > Here's the revised patch. Okay, applied and commited, thanks ! Daniel -- Daniel Veillard | Red Hat Desktop team http://redhat.com/ [EMAIL PROTECTED] | libxml GNOME XML XSLT toolkit http://xmlsoft.org/ http://veillard.c

Re: [xml] windows multi-threading

2005-02-24 Thread Rob Richards
Here's the revised patch. Rob Rich Salz wrote: Both fixes are correct. (I thought II returned the old value) Can you post a revised patch so Daniel can commit it? thanks for debugging my code. :) Index: threads.c === RCS file: /cvs

Re: [xml] windows multi-threading

2005-02-24 Thread Rich Salz
Both fixes are correct. (I thought II returned the old value) Can you post a revised patch so Daniel can commit it? thanks for debugging my code. :) -- Rich Salz Chief Security Architect DataPower Technology http://www.datapower.com XS40 XML Security Gateway http://www.d

Re: [xml] windows multi-threading

2005-02-24 Thread Rob Richards
That one does compile. Get a warning now: ..\threads.c(702) : warning C4020: 'InterlockedIncrement' : too many actual parameters Shouldn't it be: if (InterlockedIncrement(&run_once.control) == 1) removed the second parameter and test == 1 (otherwise go into a nice forever loop calling Sleep(0))

Re: [xml] windows multi-threading

2005-02-24 Thread Rich Salz
thanks. try this patch. /r$ -- Rich Salz Chief Security Architect DataPower Technology http://www.datapower.com XS40 XML Security Gateway http://www.datapower.com/products/xs40.html *** threads.c.orig Thu Feb 24 10:06:35 2005 --- threads.c Thu Feb 24 11:28

Re: [xml] windows multi-threading

2005-02-24 Thread Rob Richards
Just tried it and it breaks my build (confirmed that patch was applied correctly). Using VC++ 6 with default args other than debug=yes mem_debug=yes ..\threads.c(112) : error C2061: syntax error : identifier 'int32' ..\threads.c(114) : error C2059: syntax error : '}' ..\threads.c(701) : error C2

Re: [xml] windows multi-threading

2005-02-24 Thread Daniel Veillard
On Thu, Feb 24, 2005 at 10:15:58AM -0500, Rich Salz wrote: > > Can you generate a patch ? > > Sure, attached. Untested. The code now looks similar to the beos code. Hum, I can't test it, it didn't broke on Linux, I commited I hope someone can give it a try on Windows, thanks, Daniel --

Re: [xml] windows multi-threading

2005-02-24 Thread Rich Salz
> Can you generate a patch ? Sure, attached. Untested. The code now looks similar to the beos code. /r$ -- Rich Salz Chief Security Architect DataPower Technology http://www.datapower.com XS40 XML Security Gateway http://www.datapower.com/products/xs40.html ***

Re: [xml] windows multi-threading

2005-02-24 Thread Daniel Veillard
On Thu, Feb 24, 2005 at 09:33:11AM -0500, Rich Salz wrote: > In threads.c for the windows platform it might be better to use > InterlockedIncrement on run_once_init so that you get better pthread_once > semantics. See this link for details > http://pluto.cdpa.nsysu.edu.tw/sourceware/pthreads-win32

[xml] windows multi-threading

2005-02-24 Thread Rich Salz
In threads.c for the windows platform it might be better to use InterlockedIncrement on run_once_init so that you get better pthread_once semantics. See this link for details http://pluto.cdpa.nsysu.edu.tw/sourceware/pthreads-win32/sources/pthreads-snap-2005-01-25/pthread_once.c -- Rich Salz