MCPcopy Create free account
hub / github.com/BeneficialCode/WinArk / DetourFreeUnusedTrampolineRegions

Function DetourFreeUnusedTrampolineRegions

KernelLibrary/detours.cpp:646–662  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

644}
645
646static void DetourFreeUnusedTrampolineRegions() {
647 PDETOUR_REGION* ppRegionBase = &s_pRegions;
648 PDETOUR_REGION pRegion = s_pRegions;
649
650 while (pRegion != NULL) {
651 if (DetourIsRegionEmpty(pRegion)) {
652 *ppRegionBase = pRegion->pNext;
653 SIZE_T size = 0;
654 ExFreePoolWithTag(pRegion, 'oted');
655 s_pRegion = NULL;
656 }
657 else {
658 ppRegionBase = &pRegion->pNext;
659 }
660 pRegion = *ppRegionBase;
661 }
662}
663
664PVOID NTAPI DetourCodeFromPointer(_In_ PVOID pPointer,
665 _Out_opt_ PVOID* ppGlobals) {

Callers 1

Calls 1

DetourIsRegionEmptyFunction · 0.85

Tested by

no test coverage detected