Fix crash at process init on 64 bit XP/2003 under WOW64
* init.cc (munge_threadfunc): Don't call NtQueryInformationThread with ThreadQuerySetWin32StartAddress info class on XP 64 and Server 2003 64. It crashes. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
@@ -57,9 +57,12 @@ munge_threadfunc ()
|
||||
{
|
||||
char *threadfunc = NULL;
|
||||
|
||||
NtQueryInformationThread (NtCurrentThread (),
|
||||
ThreadQuerySetWin32StartAddress,
|
||||
&threadfunc, sizeof threadfunc, NULL);
|
||||
if (wincap.wow64_has_secondary_stack ())
|
||||
threadfunc = ebp[threadfunc_ix[0]];
|
||||
else
|
||||
NtQueryInformationThread (NtCurrentThread (),
|
||||
ThreadQuerySetWin32StartAddress,
|
||||
&threadfunc, sizeof threadfunc, NULL);
|
||||
if (!search_for || threadfunc == search_for)
|
||||
{
|
||||
search_for = NULL;
|
||||
|
Reference in New Issue
Block a user