NTSTATUS __stdcall KiSynchronizeAddressPolicyTarget(){
_ETHREAD *CurrentThread;
CurrentThread = (_ETHREAD *)KeGetCurrentThread();
if( CurrentThread->Tcb.ApcState.Process->Pcb.AddressPolicy == 1 )
{
LODWORD(CurrentThread) = KeGetPcr()->Prcb.ShadowFlags;
if( ((unsigned __int8)CurrentThread & 2) == 0 )
LODWORD(CurrentThread) = KiSetAddressPolicy(1);
}
return(int)CurrentThread;
}