1
0
mirror of https://github.com/UzixLS/KernelEx.git synced 2025-07-19 07:21:20 +03:00

import KernelEx-4.5-Final

This commit is contained in:
UzixLS
2018-11-03 16:23:17 +03:00
parent 309977e788
commit 7571e3c60d
125 changed files with 11876 additions and 9943 deletions

View File

@ -24,12 +24,12 @@
int WINAPI CommonUnimpStub(void);
#ifdef __GNUC__
#define UNIMPL_FUNC(name,params) \
__asm__( ".text\n" \
".globl _" #name "@0\n" \
"_" #name "_new@0:\n\t" \
"xor %eax, %eax\n\t" \
"movb $" #params ", %cl\n\t" \
#define UNIMPL_FUNC(name,params) \
__asm__( ".text\n" \
".globl _" #name "@0\n" \
"_" #name "_new@0:\n\t" \
"xor %eax, %eax\n\t" \
"movb $" #params ", %cl\n\t" \
"jmp _CommonUnimpStub@0\n\t" \
)
#else
@ -44,24 +44,25 @@ int WINAPI CommonUnimpStub(void);
BOOL WINAPI DllMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
{
switch (fdwReason) {
case DLL_PROCESS_ATTACH:
{
switch (fdwReason)
{
case DLL_PROCESS_ATTACH:
{
OSVERSIONINFO osv;
osv.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
GetVersionEx(&osv);
if (osv.dwMajorVersion < 5)
return FALSE;
DisableThreadLibraryCalls(hinstDLL);
break;
}
case DLL_PROCESS_DETACH:
{
break;
}
}
DisableThreadLibraryCalls(hinstDLL);
break;
}
case DLL_PROCESS_DETACH:
{
break;
}
}
return TRUE;
return TRUE;
}
UNIMPL_FUNC(PdhGetDllVersion, 1);