summaryrefslogtreecommitdiffstats
path: root/newlib/libc/stdlib/quick_exit.c
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2015-08-25 22:15:22 +0200
committerCorinna Vinschen <corinna@vinschen.de>2015-08-25 22:15:22 +0200
commit859c10beeeaaf1e0a1964118973aca1bc0460a51 (patch)
tree650a7045a6a8542493122a9bc9733782a4e2cb1b /newlib/libc/stdlib/quick_exit.c
parent70b02101ca6b5175c3e0b09757064f2aed8c3a35 (diff)
downloadcygnal-859c10beeeaaf1e0a1964118973aca1bc0460a51.tar.gz
cygnal-859c10beeeaaf1e0a1964118973aca1bc0460a51.tar.bz2
cygnal-859c10beeeaaf1e0a1964118973aca1bc0460a51.zip
autload.cc: Avoid clobbering return address in noload on i686
This fixes a long-standing problem when GetProcAddress fails to load a function. The noload code calls SetLastError on i686 without saving the edx register. Starting with Windows 7, SetLastError apparently uses $edx and the register is set to 0x00000000 on return. So the subsequent `jmp *$edx' in noload supposed to return to the caller, actually jumps to address NULL, which results in a SEGV. * autoload.cc (noload): i686 only: Save and restore $edx when calling SetLastError to avoid clobbering return address stating with Windows 7. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'newlib/libc/stdlib/quick_exit.c')
0 files changed, 0 insertions, 0 deletions