MUTANT_BASIC_INFORMATION - NtDoc

Native API online documentation, based on the System Informer (formerly Process Hacker) phnt headers
#ifndef _NTEXAPI_H
#if (PHNT_MODE != PHNT_MODE_KERNEL)

/**
 * The MUTANT_BASIC_INFORMATION structure contains basic information about a mutant object.
 * The structure is 8 bytes, but NtQueryMutant writes only the 6 bytes occupied by
 * these members. The 2 trailing padding bytes are not initialized;
 * compare members rather than the complete structure, or pre-zero the output.
 */
typedef struct _MUTANT_BASIC_INFORMATION
{
    LONG CurrentCount; // 1 when unowned; 0 for one acquisition; 1 minus the recursive acquisition count otherwise.
    BOOLEAN OwnedByCaller; // TRUE only when the calling thread is the current owner.
    BOOLEAN AbandonedState; // TRUE after an owner exits without releasing; cleared when ownership is acquired.
} MUTANT_BASIC_INFORMATION, *PMUTANT_BASIC_INFORMATION;

#endif
#endif

View code on GitHub

NtDoc

No description available.

NTinternals.net (undocumented.ntinternals.net)

Use MUTANT_BASIC_INFORMATION as a buffer in NtQueryMutant call.

CurrentCount

If CurrentCount is less than zero, mutant is signaled.

OwnedByCaller

It's TRUE if mutant is signaled by caller's thread.

AbandonedState

Is set when thread terminates without call NtReleaseMutant.

Documented by

See also