Condividi tramite


Funzione PsGetCurrentThread (ntddk.h)

La routine psGetCurrentThread identifica il thread corrente.

Sintassi

PETHREAD PsGetCurrentThread();

Valore restituito

PsGetCurrentThread restituisce un puntatore all'oggetto thread esecutivo che rappresenta il thread attualmente in esecuzione.

Osservazioni

È possibile utilizzare la macro ExGetCurrentResourceThread per restituire l'ID thread del thread corrente.

#define ExGetCurrentResourceThread() ((ULONG_PTR)PsGetCurrentThread())

Fabbisogno

Requisito Valore
client minimo supportato Disponibile a partire da Windows 2000.
piattaforma di destinazione Universale
intestazione ntddk.h (include Wdm.h, Ntddk.h, Ntifs.h)
libreria NtosKrnl.lib
dll NtosKrnl.exe
IRQL Qualsiasi livello

Vedere anche

ExSetResourceOwnerPointerEx

exReleaseResourceForThreadLite

KeGetCurrentThread

PsCreateSystemThread

PsGetCurrentProcess

PsGetCurrentProcessId

PsIsSystemThread