Re: Are PR_Locks thread re-entrant?
Rich Megginson <[email protected]>
| Newsgroups | gmane.comp.mozilla.devel.nspr |
|---|---|
| Message-ID | <[email protected]> |
Wan-Teh Chang wrote: > On Fri, Sep 19, 2008 at 4:08 PM, Rich Megginson > <[email protected]> wrote: >> That is, can you lock a mutex more than once in the same thread? We >> have a case where a function acquires a PR_Lock mutex and is called >> recursively. > > No, you can't lock a PRLock more than once in the same thread. > That's a programming error. Any suggestions? I need to allow re-entrant code in the same thread but lock out other threads. > > Wan-Teh