Browse Source
Revert "[nce] disable control flow guard on win32"
This reverts commit 963bf8ae08.
remotes/1785372757367212240/tmp_refs/heads/variable-page-size
Exverge
4 weeks ago
No known key found for this signature in database
GPG Key ID: DAD399BCC5FB77E4
1 changed files with
1 additions and
9 deletions
-
src/core/arm/nce/arm_nce.cpp
|
|
|
@ -625,15 +625,7 @@ void ArmNce::Initialize() { |
|
|
|
}); |
|
|
|
#else
|
|
|
|
static std::once_flag flag; |
|
|
|
std::call_once(flag, [] { |
|
|
|
// Initialize exception handler
|
|
|
|
AddVectoredExceptionHandler(1, VectoredExceptionHandler); |
|
|
|
|
|
|
|
// Disable control flow guard to allow context switching to guest code without causing a security error
|
|
|
|
PROCESS_MITIGATION_CONTROL_FLOW_GUARD_POLICY cfg_policy{}; |
|
|
|
cfg_policy.EnableControlFlowGuard = 0; |
|
|
|
SetProcessMitigationPolicy(ProcessControlFlowGuardPolicy, &cfg_policy, sizeof(cfg_policy)); |
|
|
|
}); |
|
|
|
std::call_once(flag, [] { AddVectoredExceptionHandler(1, VectoredExceptionHandler); }); |
|
|
|
#endif
|
|
|
|
} |
|
|
|
|
|
|
|
|