Page 1 of 1

Semaphores and Mutexes

Posted: Sat Oct 16, 2004 4:10 am
by Neo
I really looking for some quick answers here.
What is a semaphore?
What is a Mutex?
Which is used where?
Which is better?

and also another question
In Win32 if a DLL calls malloc() where is the memory allocated from local heap or global heap?

Hope i'm not all over the place. :)

Re:Semaphores and Mutexes

Posted: Sat Oct 16, 2004 7:48 am
by Pype.Clicker

Re:Semaphores and Mutexes

Posted: Sun Oct 17, 2004 6:23 am
by Neo
Any answers to the way WIN32 DLL's allocate memory?

Re:Semaphores and Mutexes

Posted: Sun Oct 24, 2004 2:22 pm
by Dreamsmith
Neo wrote:In Win32 if a DLL calls malloc() where is the memory allocated from local heap or global heap?
Calls to a DLL (including the initial call to DllMain) occur in the context of the process or thread in question, so it comes from the same place that process or thread would get memory from if it called malloc itself.