Update and rename SetLastError.c to SetLastErrorAlt.c

This commit is contained in:
vxunderground 2021-05-28 12:46:11 -05:00 committed by GitHub
orang tua 983e038035
melakukan 27e3e2193c
Tidak diketahui kunci yang ditemukan di database signature
GPG Key ID: 4AEE18F83AFDEB23

Melihat File

@ -1,5 +1,8 @@
#include <windows.h>
#include "TEB.h"
/*
DEFINITIONS FOR TEB MUST BE PRESENT
*/
PTEB GetTeb(VOID)
{
@ -10,7 +13,7 @@ PTEB GetTeb(VOID)
#endif
}
VOID SetLastErrorEx(DWORD ErrorCode)
VOID SetLastErrorAlt(DWORD ErrorCode)
{
PTEB Teb = (PTEB)GetTeb();
Teb->LastErrorValue = ErrorCode;
@ -21,7 +24,7 @@ INT main(VOID)
{
DWORD dwError = 1;
SetLastErrorEx(1);
SetLastErrorAlt(1);
return ERROR_SUCCESS;
}