[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wine-devel
Subject:    Re: libc6 threadsafety again
From:       Lionel Ulmer <ulmer () directprovider ! net>
Date:       1999-05-31 19:02:03
[Download RAW message or body]

> I doubt it. It is a clever hack, but I don't think it is a viable
> solution to the libc problem, because it isn't portable enough.  The
> real solution is to avoid using non-reentrant libc functions,
> replacing them by their Win32 equivalent. And I'm afraid that
> including your patch will reduce the motivation for fixing the problem
> correctly...

The main problem I see is not in Wine itself (that can always be
corrected), but on linked libraries : nothing prevents X libraries or
Mesa to call any libc function they want (well, for the moment it
works OK because both X and OpenGL calls are protected by the X
Critical section for other reasons).

In that case, should we create a new critical section for all
'Wine-external' library call that could rely on the thread-safeness of
the glibc ?

BTW, there are in the current CVS tree 238 occurences of 'malloc' :-)
I do not know if all of them are in 'critical code' (i.e. code that
can be called when there are multiple threads running), but it would
need some investigating.

-- 
Lionel Ulmer - bbrox@multimania.com - http://www.multimania.com/bbrox/


=========================================================================

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic