This is the mail archive of the pthreads-win32@sources.redhat.com mailing list for the pthreas-win32 project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

mutex_lock on solaris vs. winnt


Hi!

I'm trying to port some code from unix (solaris) to windows nt.
The code uses pthread mutexes to create a binary semaphore for
reading (many-at-a-time) and writing (one-at-a-time).

I have just found out that if you in unix do pthread_unix_lock
twice on the same mutex, and in the same process, you will lock. But
trying to do the same thing in windows nt (with pthread-win32 released
1999-11-02)
won't give the same behaviour. Is this because the WaitForSingleObject
in windows
will allow multiple locks in the same process? Should it be like this or
is it
something that is just not yet implemented in pthread-win32?

As you can tell I'm a newbie, and i'll appreciate very much any
information
on this. Thank you in advance.

/Hung

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]