mirror of
https://github.com/reactos/reactos.git
synced 2025-02-24 17:34:57 +00:00
Make SetUnhandledExceptionFilter return the _previous_ handler as it should. Fixes at least a winetest for ntdll (MinGW startup code got stuck in infinite loop due to this bug)
svn path=/trunk/; revision=57269
This commit is contained in:
parent
c2061cf279
commit
a84cce8d9c
1 changed files with 3 additions and 3 deletions
|
@ -435,12 +435,12 @@ LPTOP_LEVEL_EXCEPTION_FILTER
|
|||
WINAPI
|
||||
SetUnhandledExceptionFilter(IN LPTOP_LEVEL_EXCEPTION_FILTER lpTopLevelExceptionFilter)
|
||||
{
|
||||
PVOID EncodedPointer, NewPointer;
|
||||
PVOID EncodedPointer, EncodedOldPointer;
|
||||
|
||||
EncodedPointer = RtlEncodePointer(lpTopLevelExceptionFilter);
|
||||
NewPointer = InterlockedExchangePointer(&GlobalTopLevelExceptionFilter,
|
||||
EncodedOldPointer = InterlockedExchangePointer(&GlobalTopLevelExceptionFilter,
|
||||
EncodedPointer);
|
||||
return RtlDecodePointer(EncodedPointer);
|
||||
return RtlDecodePointer(EncodedOldPointer);
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in a new issue