mirror of
https://github.com/reactos/reactos.git
synced 2025-04-22 05:00:27 +00:00
[KERNEL32]
Properly implement GetLastError and export it. svn path=/trunk/; revision=50837
This commit is contained in:
parent
35587944a0
commit
cbfa1e3dbb
4 changed files with 18 additions and 3 deletions
|
@ -68,7 +68,6 @@
|
||||||
#define STARTF_SHELLPRIVATE 0x400
|
#define STARTF_SHELLPRIVATE 0x400
|
||||||
|
|
||||||
#define SetLastErrorByStatus(x) RtlSetLastWin32ErrorAndNtStatusFromNtStatus((x))
|
#define SetLastErrorByStatus(x) RtlSetLastWin32ErrorAndNtStatusFromNtStatus((x))
|
||||||
#define GetLastError() NtCurrentTeb()->LastErrorValue
|
|
||||||
|
|
||||||
typedef struct _CODEPAGE_ENTRY
|
typedef struct _CODEPAGE_ENTRY
|
||||||
{
|
{
|
||||||
|
|
|
@ -539,7 +539,7 @@
|
||||||
@ stub GetSCallbackTemplate ; missing in XP SP3 and Win 7
|
@ stub GetSCallbackTemplate ; missing in XP SP3 and Win 7
|
||||||
@ stdcall GetLargePageMinimum()
|
@ stdcall GetLargePageMinimum()
|
||||||
@ stdcall GetLargestConsoleWindowSize(long)
|
@ stdcall GetLargestConsoleWindowSize(long)
|
||||||
@ stdcall GetLastError() ntdll.RtlGetLastWin32Error
|
@ stdcall GetLastError()
|
||||||
@ stdcall GetLinguistLangSize(ptr) ; missing in Win 7
|
@ stdcall GetLinguistLangSize(ptr) ; missing in Win 7
|
||||||
@ stdcall GetLocalTime(ptr)
|
@ stdcall GetLocalTime(ptr)
|
||||||
@ stdcall GetLocaleInfoA(long long ptr long)
|
@ stdcall GetLocaleInfoA(long long ptr long)
|
||||||
|
|
|
@ -539,7 +539,7 @@
|
||||||
@ stub GetSCallbackTemplate ; missing in XP SP3 and Win 7
|
@ stub GetSCallbackTemplate ; missing in XP SP3 and Win 7
|
||||||
@ stdcall GetLargePageMinimum()
|
@ stdcall GetLargePageMinimum()
|
||||||
@ stdcall GetLargestConsoleWindowSize(long)
|
@ stdcall GetLargestConsoleWindowSize(long)
|
||||||
@ stdcall GetLastError() ntdll.RtlGetLastWin32Error
|
@ stdcall GetLastError()
|
||||||
@ stdcall GetLinguistLangSize(ptr) ; missing in Win 7
|
@ stdcall GetLinguistLangSize(ptr) ; missing in Win 7
|
||||||
@ stdcall GetLocalTime(ptr)
|
@ stdcall GetLocalTime(ptr)
|
||||||
@ stdcall GetLocaleInfoA(long long ptr long)
|
@ stdcall GetLocaleInfoA(long long ptr long)
|
||||||
|
|
|
@ -16,6 +16,9 @@ DWORD g_dwLastErrorToBreakOn;
|
||||||
|
|
||||||
/* FUNCTIONS ******************************************************************/
|
/* FUNCTIONS ******************************************************************/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @implemented
|
||||||
|
*/
|
||||||
VOID
|
VOID
|
||||||
WINAPI
|
WINAPI
|
||||||
SetLastError(
|
SetLastError(
|
||||||
|
@ -34,6 +37,9 @@ SetLastError(
|
||||||
NtCurrentTeb()->LastErrorValue = dwErrCode;
|
NtCurrentTeb()->LastErrorValue = dwErrCode;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @implemented
|
||||||
|
*/
|
||||||
VOID
|
VOID
|
||||||
WINAPI
|
WINAPI
|
||||||
BaseSetLastNTError(
|
BaseSetLastNTError(
|
||||||
|
@ -42,4 +48,14 @@ BaseSetLastNTError(
|
||||||
SetLastError(RtlNtStatusToDosError(Status));
|
SetLastError(RtlNtStatusToDosError(Status));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @implemented
|
||||||
|
*/
|
||||||
|
DWORD
|
||||||
|
WINAPI
|
||||||
|
GetLastError()
|
||||||
|
{
|
||||||
|
return NtCurrentTeb()->LastErrorValue;
|
||||||
|
}
|
||||||
|
|
||||||
/* EOF */
|
/* EOF */
|
||||||
|
|
Loading…
Reference in a new issue