Retrieves information about the owner of a mutex semaphore.

#define INCL_DOSSEMAPHORES
#include <os2.h>

HMTX      hmtx;      /*  The handle of the mutex semaphore to query. */
PID      *ppid;      /*  A pointer to the process ID of either the current owner of the mutex semaphore, or a process that has ended without releasing the semaphore. */
TID      *ptid;      /*  A pointer to the thread ID of either the current owner of the mutex semaphore, or a process that has ended without releasing the semaphore. */
PULONG    pulCount;  /*  A pointer to the request count for the semaphore. */
APIRET    ulrc;      /*  Return Code. */

ulrc = DosQueryMutexSem(hmtx, ppid, ptid,
         pulCount);


[Back] [Next]