Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
/*
|
|
|
|
* Debugger stack handling
|
|
|
|
*
|
|
|
|
* Copyright 1995 Alexandre Julliard
|
1996-12-22 19:27:48 +01:00
|
|
|
* Copyright 1996 Eric Youngdale
|
2008-10-18 19:22:19 +02:00
|
|
|
* Copyright 1999 Ove KÃ¥ven
|
2002-03-10 00:29:33 +01:00
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2.1 of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library; if not, write to the Free Software
|
2006-05-18 14:49:52 +02:00
|
|
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
*/
|
|
|
|
|
1999-02-28 20:59:00 +01:00
|
|
|
#include "config.h"
|
2000-03-08 19:26:56 +01:00
|
|
|
|
1997-05-09 10:40:27 +02:00
|
|
|
#include <stdlib.h>
|
2005-05-29 22:03:56 +02:00
|
|
|
#include <stdio.h>
|
2000-03-08 19:26:56 +01:00
|
|
|
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
#include "debugger.h"
|
2000-03-08 19:26:56 +01:00
|
|
|
#include "winbase.h"
|
2005-05-16 16:20:16 +02:00
|
|
|
#include "wine/winbase16.h"
|
2004-06-23 02:10:02 +02:00
|
|
|
#include "tlhelp32.h"
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
|
|
|
|
/***********************************************************************
|
2004-06-04 02:59:16 +02:00
|
|
|
* stack_info
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
*
|
2010-05-25 00:48:36 +02:00
|
|
|
* Dump the top of the stack. If len <= 0, a default length is used.
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
*/
|
2010-05-25 00:48:36 +02:00
|
|
|
void stack_info(int len)
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
{
|
2005-03-03 15:10:17 +01:00
|
|
|
struct dbg_lvalue lvalue;
|
|
|
|
|
2010-05-25 00:48:36 +02:00
|
|
|
if(len <= 0)
|
|
|
|
len = 24;
|
|
|
|
|
2005-03-03 15:10:17 +01:00
|
|
|
lvalue.cookie = 0;
|
2006-02-20 11:03:33 +01:00
|
|
|
lvalue.type.id = dbg_itype_segptr;
|
2005-03-03 15:10:17 +01:00
|
|
|
lvalue.type.module = 0;
|
2002-06-01 01:06:46 +02:00
|
|
|
|
2004-06-04 02:59:16 +02:00
|
|
|
/* FIXME: we assume stack grows the same way as on i386 */
|
2005-03-03 15:10:17 +01:00
|
|
|
if (!memory_get_current_stack(&lvalue.addr))
|
|
|
|
dbg_printf("Bad segment (%d)\n", lvalue.addr.Segment);
|
Release 950817
Thu Aug 17 19:30:14 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [*/Makefile.in]
Removed winelibclean target, as it doesn't work anyway.
* [controls/button.c]
Avoid drawing the focus rectangle outside of the button.
* [controls/widgets.c]
Fixed bug with the size of the reserved bytes for the Edit
control (caused Eudora to crash).
* [debugger/*] [include/debugger.h]
Unified debugger address handling. Segmented and linear addresses
are no grouped in a single type DBG_ADDR.
All commands now accept seg:off addresses.
Module entry points are now loaded upon first entry to the
debugger, so that entry points of the loaded executable also
appear in the symbol table.
* [include/registers.h] [miscemu/*.c]
Register macros are now of the form 'AX_reg(context)' instead of 'AX'.
This makes code less readable, but will prevent a lot of name
clashes with other definitions. It also avoids a hidden reference
to the 'context' variable.
* [ipc/dde_atom.c] [misc/atom.c]
All *AddAtom and *FindAtom functions now take a SEGPTR parameter,
to allow supporting integer atoms.
Moved atom.c to memory/ directory.
* [loader/task.c]
Fixed environment allocation to compute the size dynamically.
Added 'windir' environment variable.
Fixed GetDOSEnvironment() to return the current task environment.
* [windows/message.c]
Fixed bug in MSG_GetWindowForEvent().
Wed Aug 9 11:40:43 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [include/ole.h]
Added a lot of structures from my Borland Manual. Neither complete,
nor 100% right (check please)
* [misc/shell.c]
Fixed some of the Reg* functions.
Enhanced ShellExecute.
Please test: wine "regedit.exe /v" mplayer.exe soundrec.exe
Do YOU know the format of \WINDOWS\REG.DAT? Mail me please :)
* [misc/dos_fs.c]
Make umsdos mounted windows dirs work again.
* [miscemu/emulate.c]
Added some comments, preimplementation of subfunction 7.
* [multimedia/mmsystem.c]
Implemented mciSendString. not complete, not clean, not
necessarily working (only checked with a program which uses
'cdaudio' (one working program is cool.exe, a shareware waveditor
with cdaudio play facilities.)
* [multimedia/mcicda.c]
Segptr fixes in DriverProc
Default cdrom drive in Linux is /dev/cdrom ... usually a symbolic
link to your real cdrom device.
Tue Aug 8 19:41:50 CDT 1995 Daniel Schepler <dks2@cec.wustl.edu>
* [loader/resource.c]
Don't crash in a LoadString to NULL
* [loader/resource.c]
Fixed accelerators to work with modifiers. (ALT-x modifiers still
won't work unless the ALT keypress exited the menu.)
* [misc/file.c]
Expand a file to the current offset with an _lwrite of size zero.
* [misc/file.c]
Set a newly created file to read-write instead of write-only.
Sun Aug 6 20:28:35 1995 Anand Kumria <akumria@ozemail.com.au>
* [misc/main.c] [include/msdos.h]
Fixed to return DOS version 6.22, and the correct byte order
for Windows programs.
Wed Aug 2 12:36:33 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [include/options.h] [memory/global.c] [misc/main.c]
Make the new IPC run-time selectible, disabling it by default.
(I think it's only useful for libwine, anyway.)
* [loader/task.c] [memory/selector.c]
In FreeSelector(), walk up the stack and fix the frames.
* [objects/dib.c]
Missing break statement in DIB_SetImageBits_RLE8().
In GetDIBits(), set the compression flag in the bitmap info to zero.
* [windows/dialog.c]
GetNextDlgGroupItem() needs to treat the first child as if it had
an implicit WS_GROUP bit set.
Mon Jul 31 15:44:47 EDT 1995 Louis-D. Dubeau <ldd@step.polymtl.ca>
* [misc/dos_fs.c]
Quick'n dirty fix for the initialisation of the Z: information
structure.
1995-08-17 19:11:36 +02:00
|
|
|
|
2004-06-04 02:59:16 +02:00
|
|
|
dbg_printf("Stack dump:\n");
|
2005-03-03 15:10:17 +01:00
|
|
|
switch (lvalue.addr.Mode)
|
2000-09-24 05:15:50 +02:00
|
|
|
{
|
2010-04-19 22:33:26 +02:00
|
|
|
case AddrModeFlat: /* 32-bit or 64-bit mode */
|
2010-05-25 00:48:36 +02:00
|
|
|
memory_examine(&lvalue, len, 'a');
|
2010-04-19 22:33:26 +02:00
|
|
|
break;
|
2004-06-04 02:59:16 +02:00
|
|
|
case AddrMode1632: /* 32-bit mode */
|
2010-05-25 00:48:36 +02:00
|
|
|
memory_examine(&lvalue, len, 'x');
|
2004-06-04 02:59:16 +02:00
|
|
|
break;
|
|
|
|
case AddrModeReal: /* 16-bit mode */
|
|
|
|
case AddrMode1616:
|
2010-05-25 00:48:36 +02:00
|
|
|
memory_examine(&lvalue, len, 'w');
|
2000-03-08 17:44:54 +01:00
|
|
|
break;
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2005-11-18 13:33:03 +01:00
|
|
|
static BOOL stack_set_frame_internal(int newframe)
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
{
|
2005-11-18 13:33:03 +01:00
|
|
|
if (newframe >= dbg_curr_thread->num_frames)
|
|
|
|
newframe = dbg_curr_thread->num_frames - 1;
|
|
|
|
if (newframe < 0)
|
|
|
|
newframe = 0;
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
|
2005-11-18 13:33:03 +01:00
|
|
|
if (dbg_curr_thread->curr_frame != newframe)
|
|
|
|
{
|
|
|
|
IMAGEHLP_STACK_FRAME ihsf;
|
2002-06-01 01:06:46 +02:00
|
|
|
|
2005-11-18 13:33:03 +01:00
|
|
|
dbg_curr_thread->curr_frame = newframe;
|
|
|
|
stack_get_current_frame(&ihsf);
|
|
|
|
SymSetContext(dbg_curr_process->handle, &ihsf, NULL);
|
|
|
|
}
|
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
2005-11-29 11:24:04 +01:00
|
|
|
static BOOL stack_get_frame(int nf, IMAGEHLP_STACK_FRAME* ihsf)
|
2005-11-18 16:04:44 +01:00
|
|
|
{
|
2006-02-16 12:06:43 +01:00
|
|
|
memset(ihsf, 0, sizeof(*ihsf));
|
2006-12-02 17:43:08 +01:00
|
|
|
ihsf->InstructionOffset = dbg_curr_thread->frames[nf].linear_pc;
|
2010-03-30 21:37:22 +02:00
|
|
|
/* if we're not the first frame, InstructionOffset is the return address
|
|
|
|
* after the call instruction (at least on most processors I know of).
|
|
|
|
* However, there are cases where this address is outside of the current function.
|
|
|
|
* This happens when the called function is marked <NO RETURN>, in which
|
|
|
|
* case the compiler can omit the epilog (gcc 4 does it)
|
|
|
|
* Therefore, we decrement InstructionOffset in order to ensure that
|
|
|
|
* the considered address is really inside the current function.
|
|
|
|
*/
|
|
|
|
if (nf) ihsf->InstructionOffset--;
|
2006-12-02 17:43:08 +01:00
|
|
|
ihsf->FrameOffset = dbg_curr_thread->frames[nf].linear_frame;
|
2010-03-30 21:37:08 +02:00
|
|
|
ihsf->StackOffset = dbg_curr_thread->frames[nf].linear_stack;
|
2005-11-18 16:04:44 +01:00
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
2005-11-18 13:33:03 +01:00
|
|
|
BOOL stack_get_current_frame(IMAGEHLP_STACK_FRAME* ihsf)
|
|
|
|
{
|
|
|
|
/*
|
|
|
|
* If we don't have a valid backtrace, then just return.
|
|
|
|
*/
|
|
|
|
if (dbg_curr_thread->frames == NULL) return FALSE;
|
2005-11-29 11:24:04 +01:00
|
|
|
return stack_get_frame(dbg_curr_thread->curr_frame, ihsf);
|
2005-11-18 13:33:03 +01:00
|
|
|
}
|
|
|
|
|
2010-03-30 21:37:01 +02:00
|
|
|
BOOL stack_get_register_frame(const struct dbg_internal_var* div, DWORD_PTR** pval)
|
|
|
|
{
|
|
|
|
if (dbg_curr_thread->frames == NULL) return FALSE;
|
|
|
|
if (dbg_curr_thread->frames[dbg_curr_thread->curr_frame].is_ctx_valid)
|
|
|
|
*pval = (DWORD_PTR*)((char*)&dbg_curr_thread->frames[dbg_curr_thread->curr_frame].context +
|
|
|
|
(DWORD_PTR)div->pval);
|
|
|
|
else
|
|
|
|
{
|
|
|
|
enum be_cpu_addr kind;
|
|
|
|
|
|
|
|
if (!be_cpu->get_register_info(div->val, &kind)) return FALSE;
|
|
|
|
|
|
|
|
/* reuse some known registers directly out of stackwalk details */
|
|
|
|
switch (kind)
|
|
|
|
{
|
|
|
|
case be_cpu_addr_pc:
|
|
|
|
*pval = &dbg_curr_thread->frames[dbg_curr_thread->curr_frame].linear_pc;
|
|
|
|
break;
|
|
|
|
case be_cpu_addr_stack:
|
|
|
|
*pval = &dbg_curr_thread->frames[dbg_curr_thread->curr_frame].linear_stack;
|
|
|
|
break;
|
|
|
|
case be_cpu_addr_frame:
|
|
|
|
*pval = &dbg_curr_thread->frames[dbg_curr_thread->curr_frame].linear_frame;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
2005-11-18 13:33:03 +01:00
|
|
|
BOOL stack_set_frame(int newframe)
|
|
|
|
{
|
2006-07-26 11:57:27 +02:00
|
|
|
ADDRESS64 addr;
|
2005-11-18 13:33:03 +01:00
|
|
|
if (!stack_set_frame_internal(newframe)) return FALSE;
|
2004-06-04 02:59:16 +02:00
|
|
|
addr.Mode = AddrModeFlat;
|
2009-12-14 22:05:16 +01:00
|
|
|
addr.Offset = (DWORD_PTR)memory_to_linear_addr(&dbg_curr_thread->frames[dbg_curr_thread->curr_frame].addr_pc);
|
2004-06-04 02:59:16 +02:00
|
|
|
source_list_from_addr(&addr, 0);
|
1999-05-08 14:38:20 +02:00
|
|
|
return TRUE;
|
Release 950706
Wed Jul 5 19:06:35 1995 Alexandre Julliard <julliard@sunsite.unc.edu>
* [controls/scroll.c]
Fixed drawing bug that caused part of a non-client scroll bar
to be painted even when the scroll-bar was hidden.
* [debugger/break.c] [debugger/dbg.y]
Rewrote breakpoint handling to work in 16-bit mode.
Implemented single-stepping ('step' and 'next' instructions).
* [debugger/debug.l]
Format specifier is now a separate token.
Entering an empty line at the debugger prompt causes the previous
command to be repeated, like under gdb.
* [debugger/debug.l] [debugger/registers.c]
Differentiate 16-bit and 32-bit registers without taking current
mode into account ($eax is always 32-bit, $ax always 16-bit).
* [debugger/stack.c]
Fixed stack information routines to differentiate between 16-bit
and 32-bit stacks.
* [loader/task.c]
Option -debug now sets a breakpoint at the first instruction of
every loaded task.
* [miscemu/instr.c]
Added handling of lock, repe and repne prefixes.
* [objects/dib.c]
Changed StretchDIBits() to do the correct thing, even if it's still
not really optimal.
* [windows/graphics.c]
Fixes in RoundRect(), thanks to Babak Masalehdan.
* [windows/message.c]
Tried to fix mouse event handling with respect to disabled
windows.
* [windows/painting.c]
Clear WIN_NEEDS_NCPAINT flag before sending WM_NCPAINT to avoid
infinite loops.
* [windows/win.c]
Fixed IsWindowVisible() to return FALSE when one of the parent
windows is hidden.
Sat Jul 1 22:08:21 1995 Martin von Loewis <loewis@informatik.hu-berlin.de>
* [if1632/compobj.spec][misc/compobj.c]
CoGetMalloc: New function
Added relay entries for COMPOBJ ordinals above 100
CoInitialize: Changed parameter to DWORD
* [if1632/ole2.spec]
Exported implementation of OleBuildVersion
* [if1632/ole2disp.spec][misc/ole2disp.c][misc/Imakefile]
ole2disp.c: New file
SysAllocString, SysReallocString, SysAllocStringLen,
SysReAllocStringLen, SysFreeString, SysStringLen: new functions
* [if1632/ole2nls.spec][include/winnls.h][misc/ole2nls.c]
CompareStringA: New function
Thu Jun 29 19:42:02 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [objects/font.c] [if1632/gdi.spec]
New stubs for CreateScalableFontResource, GetGlyphOutline.
Thu Jun 29 13:47:08 GMT 1995 Göran Thyni (goran@norrsken.bildbasen.se)
* [misc/commdlg.c]
Extensive changes and bug fixes to FileDialog handling,
behaves more like native Windows.
Wed Jun 28 13:04:44 1995 Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>
* [controls/listbox.c] [controls/combo.c]
Some minor optimizations.
* [memory/local.c]
LOCAL_FindFreeBlock(): Never use the last one.
* [memory/global.c]
GlobalReAlloc(): GMEM_MODIFY must not be ignored when size==0.
* [misc/file.c]
read() returns an error when length==0. This is not what Windows
programs expect, so pay attention to this in _lread(). Changed this
in _lwrite(), _hread(), _hwrite(), too.
* [loader/resource.c]
LoadIcon(): Ignore bih->biSizeImage, some icons have wrong values in
there.
* [if1632/shell.spec] [misc/shell.c]
Wrong spec file entries caused havoc: HKEY has 32 bit, not 16.
Accept some more combinations of parameters in the Reg..() functions.
* [if1632/toolhelp.spec]
Make InterruptRegister() and InterruptUnregister() return false.
* [windows/hook.c]
CallNextHookEx() used to crash when called with a null hhook. Fixed.
Wed Jun 28 10:14:34 1995 Martin von Loewis <martin@informatik.hu-berlin.de>
* [include/neexe.h][loader/ne_image.c]
NE_LoadSegment: Detect iterated segments
* [misc/ole2nls.c]
LOCALE_SLONGDATE: fixed typo
* [miscemu/int5c.c]
Reordered include files to avoid conflicts with Linux libc.5.1
* [rc/winerc.c]
Added -b option to process binary resource files into C arrays
* [include/callback.h]
CallWndProc: Added dummy ds parameter for libwine
* [include/gdi.h][include/user.h]
USER_HEAP_ALLOC, GDI_HEAP_ALLOC: dropped flags parameter
* [include/ldt.h][include/stackframe.h]
defined segment conversion macros for libwine
* [misc/atom.c]
Defined USER_HeapSel for libwine
* [misc/main.c]
Disable -dll option for libwine
* [misc/user.c]
removed GetFreeSystemResources, SystemHeapInfo from libwine for now
* [toolkit/heap.c]
fixed LocalLock prototype
* [toolkit/sup.c]
sync'ed load_mz_header, load_ne_header with structures
* [toolkit/winmain.c]
Disabled resource DLLs for libwine for now
Mon Jun 26 19:30:24 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/main.c]
Fixed -enhanced option to report a 386 CPU instead of a 286.
Fri Jun 23 23:18:25 1995 Marcus Meissner <msmeissn@faui01.informatik.uni-erlangen.de>
* [misc/dos_fs.c]
Remove maximum open dosdirent limit (fixing the winfile.exe
problem) by using telldir()/seekdir().
Fri Jun 23 13:42:25 1995 Hans de Graaff (graaff@twi72.twi.tudelft.nl)
* [misc/profile.c]
Fixed problem parsing empty lines within sections in .ini files.
1995-07-06 19:18:27 +02:00
|
|
|
}
|
1996-12-22 19:27:48 +01:00
|
|
|
|
2005-11-29 11:24:04 +01:00
|
|
|
/******************************************************************
|
|
|
|
* stack_get_current_symbol
|
|
|
|
*
|
|
|
|
* Retrieves the symbol information for the current frame element
|
|
|
|
*/
|
|
|
|
BOOL stack_get_current_symbol(SYMBOL_INFO* symbol)
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
2005-11-29 11:24:04 +01:00
|
|
|
IMAGEHLP_STACK_FRAME ihsf;
|
|
|
|
DWORD64 disp;
|
2000-08-01 01:27:20 +02:00
|
|
|
|
2005-11-29 11:24:04 +01:00
|
|
|
if (!stack_get_current_frame(&ihsf)) return FALSE;
|
|
|
|
return SymFromAddr(dbg_curr_process->handle, ihsf.InstructionOffset,
|
|
|
|
&disp, symbol);
|
1999-05-08 14:38:20 +02:00
|
|
|
}
|
2006-03-01 21:05:35 +01:00
|
|
|
|
2006-07-26 11:57:27 +02:00
|
|
|
static BOOL CALLBACK stack_read_mem(HANDLE hProc, DWORD64 addr,
|
2006-03-01 21:05:35 +01:00
|
|
|
PVOID buffer, DWORD size, PDWORD written)
|
|
|
|
{
|
2006-06-30 21:37:38 +02:00
|
|
|
SIZE_T sz;
|
|
|
|
BOOL ret;
|
|
|
|
|
2006-03-01 21:05:35 +01:00
|
|
|
struct dbg_process* pcs = dbg_get_process_h(hProc);
|
|
|
|
if (!pcs) return FALSE;
|
2006-07-26 11:57:27 +02:00
|
|
|
ret = pcs->process_io->read(hProc, (const void*)(DWORD_PTR)addr, buffer,
|
|
|
|
size, &sz);
|
2006-06-30 21:37:38 +02:00
|
|
|
if (written != NULL) *written = sz;
|
|
|
|
return ret;
|
2006-03-01 21:05:35 +01:00
|
|
|
}
|
|
|
|
|
2005-05-29 22:03:56 +02:00
|
|
|
/******************************************************************
|
2005-11-18 13:33:03 +01:00
|
|
|
* stack_fetch_frames
|
2005-05-29 22:03:56 +02:00
|
|
|
*
|
2007-10-23 15:30:30 +02:00
|
|
|
* Do a backtrace on the current thread
|
2005-05-29 22:03:56 +02:00
|
|
|
*/
|
2010-03-30 21:37:01 +02:00
|
|
|
unsigned stack_fetch_frames(const CONTEXT* _ctx)
|
1999-05-08 14:38:20 +02:00
|
|
|
{
|
2006-07-26 11:57:27 +02:00
|
|
|
STACKFRAME64 sf;
|
|
|
|
unsigned nf = 0;
|
2006-08-13 20:46:54 +02:00
|
|
|
/* as native stackwalk can modify the context passed to it, simply copy
|
|
|
|
* it to avoid any damage
|
|
|
|
*/
|
2011-03-13 21:30:40 +01:00
|
|
|
CONTEXT ctx = *_ctx;
|
2012-01-03 21:37:49 +01:00
|
|
|
BOOL ret;
|
2004-06-23 02:10:02 +02:00
|
|
|
|
2005-11-18 13:33:03 +01:00
|
|
|
HeapFree(GetProcessHeap(), 0, dbg_curr_thread->frames);
|
|
|
|
dbg_curr_thread->frames = NULL;
|
|
|
|
|
2004-06-04 02:59:16 +02:00
|
|
|
memset(&sf, 0, sizeof(sf));
|
2010-06-30 21:16:24 +02:00
|
|
|
be_cpu->get_addr(dbg_curr_thread->handle, &ctx, be_cpu_addr_frame, &sf.AddrFrame);
|
|
|
|
be_cpu->get_addr(dbg_curr_thread->handle, &ctx, be_cpu_addr_pc, &sf.AddrPC);
|
|
|
|
be_cpu->get_addr(dbg_curr_thread->handle, &ctx, be_cpu_addr_stack, &sf.AddrStack);
|
2004-06-04 02:59:16 +02:00
|
|
|
|
2004-09-23 06:27:46 +02:00
|
|
|
/* don't confuse StackWalk by passing in inconsistent addresses */
|
|
|
|
if ((sf.AddrPC.Mode == AddrModeFlat) && (sf.AddrFrame.Mode != AddrModeFlat))
|
|
|
|
{
|
2009-01-08 17:34:26 +01:00
|
|
|
sf.AddrFrame.Offset = (ULONG_PTR)memory_to_linear_addr(&sf.AddrFrame);
|
2004-09-23 06:27:46 +02:00
|
|
|
sf.AddrFrame.Mode = AddrModeFlat;
|
|
|
|
}
|
|
|
|
|
2012-01-03 21:37:49 +01:00
|
|
|
while ((ret = StackWalk64(be_cpu->machine, dbg_curr_process->handle,
|
|
|
|
dbg_curr_thread->handle, &sf, &ctx, stack_read_mem,
|
|
|
|
SymFunctionTableAccess64, SymGetModuleBase64, NULL)) ||
|
|
|
|
nf == 0) /* we always register first frame information */
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
2012-01-03 21:37:49 +01:00
|
|
|
dbg_curr_thread->frames = dbg_heap_realloc(dbg_curr_thread->frames,
|
2005-11-18 13:33:03 +01:00
|
|
|
(nf + 1) * sizeof(dbg_curr_thread->frames[0]));
|
1996-12-22 19:27:48 +01:00
|
|
|
|
2006-12-02 17:43:08 +01:00
|
|
|
dbg_curr_thread->frames[nf].addr_pc = sf.AddrPC;
|
2009-12-10 15:23:45 +01:00
|
|
|
dbg_curr_thread->frames[nf].linear_pc = (DWORD_PTR)memory_to_linear_addr(&sf.AddrPC);
|
2006-12-02 17:43:08 +01:00
|
|
|
dbg_curr_thread->frames[nf].addr_frame = sf.AddrFrame;
|
2009-12-10 15:23:45 +01:00
|
|
|
dbg_curr_thread->frames[nf].linear_frame = (DWORD_PTR)memory_to_linear_addr(&sf.AddrFrame);
|
2006-12-02 17:43:08 +01:00
|
|
|
dbg_curr_thread->frames[nf].addr_stack = sf.AddrStack;
|
2009-12-10 15:23:45 +01:00
|
|
|
dbg_curr_thread->frames[nf].linear_stack = (DWORD_PTR)memory_to_linear_addr(&sf.AddrStack);
|
2011-03-13 21:30:40 +01:00
|
|
|
dbg_curr_thread->frames[nf].context = ctx;
|
2010-03-30 21:37:01 +02:00
|
|
|
/* FIXME: can this heuristic be improved: we declare first context always valid, and next ones
|
|
|
|
* if it has been modified by the call to StackWalk...
|
|
|
|
*/
|
|
|
|
dbg_curr_thread->frames[nf].is_ctx_valid =
|
|
|
|
(nf == 0 ||
|
|
|
|
(dbg_curr_thread->frames[nf - 1].is_ctx_valid &&
|
|
|
|
memcmp(&dbg_curr_thread->frames[nf - 1].context, &ctx, sizeof(ctx))));
|
2004-06-04 02:59:16 +02:00
|
|
|
nf++;
|
2012-01-03 21:37:49 +01:00
|
|
|
/* bail if:
|
|
|
|
* - we've (probably) gotten ourselves into an infinite loop,
|
|
|
|
* - or StackWalk failed on first frame
|
|
|
|
*/
|
|
|
|
if (nf > 200 || !ret) break;
|
2005-11-18 13:33:03 +01:00
|
|
|
}
|
2005-11-18 17:27:55 +01:00
|
|
|
dbg_curr_thread->curr_frame = -1;
|
|
|
|
dbg_curr_thread->num_frames = nf;
|
|
|
|
stack_set_frame_internal(0);
|
|
|
|
return nf;
|
2005-11-18 13:33:03 +01:00
|
|
|
}
|
|
|
|
|
2005-11-18 16:04:44 +01:00
|
|
|
struct sym_enum
|
|
|
|
{
|
2009-12-10 15:23:45 +01:00
|
|
|
DWORD_PTR frame;
|
2006-11-24 22:18:42 +01:00
|
|
|
BOOL first;
|
2005-11-18 16:04:44 +01:00
|
|
|
};
|
|
|
|
|
2007-09-18 00:40:19 +02:00
|
|
|
static BOOL WINAPI sym_enum_cb(PSYMBOL_INFO sym_info, ULONG size, PVOID user)
|
2005-11-18 16:04:44 +01:00
|
|
|
{
|
2009-04-21 09:59:59 +02:00
|
|
|
struct sym_enum* se = user;
|
2005-11-18 16:04:44 +01:00
|
|
|
|
2006-02-06 11:27:32 +01:00
|
|
|
if (sym_info->Flags & SYMFLAG_PARAMETER)
|
2005-11-18 16:04:44 +01:00
|
|
|
{
|
2006-11-24 22:18:42 +01:00
|
|
|
if (!se->first) dbg_printf(", "); else se->first = FALSE;
|
|
|
|
symbol_print_local(sym_info, se->frame, FALSE);
|
2005-11-18 16:04:44 +01:00
|
|
|
}
|
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
static void stack_print_addr_and_args(int nf)
|
|
|
|
{
|
|
|
|
char buffer[sizeof(SYMBOL_INFO) + 256];
|
|
|
|
SYMBOL_INFO* si = (SYMBOL_INFO*)buffer;
|
|
|
|
IMAGEHLP_STACK_FRAME ihsf;
|
2009-12-12 12:19:44 +01:00
|
|
|
IMAGEHLP_LINE64 il;
|
2005-11-18 16:04:44 +01:00
|
|
|
IMAGEHLP_MODULE im;
|
|
|
|
DWORD64 disp64;
|
|
|
|
|
|
|
|
print_bare_address(&dbg_curr_thread->frames[nf].addr_pc);
|
|
|
|
|
2005-11-29 11:24:04 +01:00
|
|
|
stack_get_frame(nf, &ihsf);
|
2005-11-18 16:04:44 +01:00
|
|
|
|
|
|
|
/* grab module where symbol is. If we don't have a module, we cannot print more */
|
|
|
|
im.SizeOfStruct = sizeof(im);
|
|
|
|
if (!SymGetModuleInfo(dbg_curr_process->handle, ihsf.InstructionOffset, &im))
|
|
|
|
return;
|
|
|
|
|
|
|
|
si->SizeOfStruct = sizeof(*si);
|
|
|
|
si->MaxNameLen = 256;
|
|
|
|
if (SymFromAddr(dbg_curr_process->handle, ihsf.InstructionOffset, &disp64, si))
|
|
|
|
{
|
|
|
|
struct sym_enum se;
|
|
|
|
DWORD disp;
|
|
|
|
|
|
|
|
dbg_printf(" %s", si->Name);
|
2006-02-16 12:06:43 +01:00
|
|
|
if (disp64) dbg_printf("+0x%lx", (DWORD_PTR)disp64);
|
2005-11-18 16:04:44 +01:00
|
|
|
|
|
|
|
SymSetContext(dbg_curr_process->handle, &ihsf, NULL);
|
2006-11-24 22:18:42 +01:00
|
|
|
se.first = TRUE;
|
2005-11-18 16:04:44 +01:00
|
|
|
se.frame = ihsf.FrameOffset;
|
2006-11-24 22:18:42 +01:00
|
|
|
dbg_printf("(");
|
2005-11-18 16:04:44 +01:00
|
|
|
SymEnumSymbols(dbg_curr_process->handle, 0, NULL, sym_enum_cb, &se);
|
2006-11-24 22:18:42 +01:00
|
|
|
dbg_printf(")");
|
2005-11-18 16:04:44 +01:00
|
|
|
|
|
|
|
il.SizeOfStruct = sizeof(il);
|
2009-12-12 12:19:44 +01:00
|
|
|
if (SymGetLineFromAddr64(dbg_curr_process->handle,
|
|
|
|
ihsf.InstructionOffset, &disp, &il))
|
2006-12-20 14:17:27 +01:00
|
|
|
dbg_printf(" [%s:%u]", il.FileName, il.LineNumber);
|
2005-11-18 16:04:44 +01:00
|
|
|
dbg_printf(" in %s", im.ModuleName);
|
|
|
|
}
|
|
|
|
else dbg_printf(" in %s (+0x%lx)",
|
|
|
|
im.ModuleName, (DWORD_PTR)(ihsf.InstructionOffset - im.BaseOfImage));
|
|
|
|
}
|
|
|
|
|
2005-11-18 13:33:03 +01:00
|
|
|
/******************************************************************
|
|
|
|
* backtrace
|
|
|
|
*
|
2007-10-23 15:30:30 +02:00
|
|
|
* Do a backtrace on the current thread
|
2005-11-18 13:33:03 +01:00
|
|
|
*/
|
2006-02-06 11:27:32 +01:00
|
|
|
static void backtrace(void)
|
2005-11-18 13:33:03 +01:00
|
|
|
{
|
2006-02-06 11:27:32 +01:00
|
|
|
unsigned cf = dbg_curr_thread->curr_frame;
|
2005-11-18 17:27:55 +01:00
|
|
|
IMAGEHLP_STACK_FRAME ihsf;
|
2005-11-18 13:33:03 +01:00
|
|
|
|
|
|
|
dbg_printf("Backtrace:\n");
|
2006-02-06 11:27:32 +01:00
|
|
|
for (dbg_curr_thread->curr_frame = 0;
|
|
|
|
dbg_curr_thread->curr_frame < dbg_curr_thread->num_frames;
|
|
|
|
dbg_curr_thread->curr_frame++)
|
2005-11-18 13:33:03 +01:00
|
|
|
{
|
|
|
|
dbg_printf("%s%d ",
|
2006-02-06 11:27:32 +01:00
|
|
|
(cf == dbg_curr_thread->curr_frame ? "=>" : " "),
|
2008-12-06 19:00:10 +01:00
|
|
|
dbg_curr_thread->curr_frame);
|
2006-02-06 11:27:32 +01:00
|
|
|
stack_print_addr_and_args(dbg_curr_thread->curr_frame);
|
2005-11-18 13:33:03 +01:00
|
|
|
dbg_printf(" (");
|
2006-10-17 21:10:29 +02:00
|
|
|
print_bare_address(&dbg_curr_thread->frames[dbg_curr_thread->curr_frame].addr_frame);
|
2005-11-18 13:33:03 +01:00
|
|
|
dbg_printf(")\n");
|
1996-12-22 19:27:48 +01:00
|
|
|
}
|
2005-11-18 17:27:55 +01:00
|
|
|
/* reset context to current stack frame */
|
2006-02-06 11:27:32 +01:00
|
|
|
dbg_curr_thread->curr_frame = cf;
|
2006-06-15 11:38:43 +02:00
|
|
|
if (!dbg_curr_thread->frames) return;
|
2005-11-29 11:24:04 +01:00
|
|
|
stack_get_frame(dbg_curr_thread->curr_frame, &ihsf);
|
2005-11-18 17:27:55 +01:00
|
|
|
SymSetContext(dbg_curr_process->handle, &ihsf, NULL);
|
2005-05-29 22:03:56 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
/******************************************************************
|
|
|
|
* backtrace_tid
|
|
|
|
*
|
|
|
|
* Do a backtrace on a thread from its process and its identifier
|
|
|
|
* (preserves current thread and context information)
|
|
|
|
*/
|
2005-11-18 13:33:03 +01:00
|
|
|
static void backtrace_tid(struct dbg_process* pcs, DWORD tid)
|
2005-05-29 22:03:56 +02:00
|
|
|
{
|
|
|
|
struct dbg_thread* thread = dbg_curr_thread;
|
1996-12-22 19:27:48 +01:00
|
|
|
|
2005-05-29 22:03:56 +02:00
|
|
|
if (!(dbg_curr_thread = dbg_get_thread(pcs, tid)))
|
2006-12-20 14:17:27 +01:00
|
|
|
dbg_printf("Unknown thread id (%04x) in process (%04x)\n", tid, pcs->pid);
|
2005-05-29 22:03:56 +02:00
|
|
|
else
|
|
|
|
{
|
2010-03-30 21:37:01 +02:00
|
|
|
CONTEXT context;
|
2005-05-29 22:03:56 +02:00
|
|
|
|
|
|
|
dbg_curr_tid = dbg_curr_thread->tid;
|
2010-03-30 21:37:01 +02:00
|
|
|
memset(&context, 0, sizeof(context));
|
|
|
|
context.ContextFlags = CONTEXT_FULL;
|
2005-05-29 22:03:56 +02:00
|
|
|
if (SuspendThread(dbg_curr_thread->handle) != -1)
|
|
|
|
{
|
2010-03-30 21:37:01 +02:00
|
|
|
if (!GetThreadContext(dbg_curr_thread->handle, &context))
|
2005-05-29 22:03:56 +02:00
|
|
|
{
|
2006-12-20 14:17:27 +01:00
|
|
|
dbg_printf("Can't get context for thread %04x in current process\n",
|
2005-05-29 22:03:56 +02:00
|
|
|
tid);
|
|
|
|
}
|
2006-05-14 18:08:43 +02:00
|
|
|
else
|
|
|
|
{
|
2010-03-30 21:37:01 +02:00
|
|
|
stack_fetch_frames(&context);
|
2006-05-14 18:08:43 +02:00
|
|
|
backtrace();
|
|
|
|
}
|
2005-05-29 22:03:56 +02:00
|
|
|
ResumeThread(dbg_curr_thread->handle);
|
|
|
|
}
|
2006-12-20 14:17:27 +01:00
|
|
|
else dbg_printf("Can't suspend thread %04x in current process\n", tid);
|
2005-05-29 22:03:56 +02:00
|
|
|
}
|
|
|
|
dbg_curr_thread = thread;
|
|
|
|
dbg_curr_tid = thread ? thread->tid : 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
/******************************************************************
|
|
|
|
* backtrace_all
|
|
|
|
*
|
|
|
|
* Do a backtrace on every running thread in the system (except the debugger)
|
|
|
|
* (preserves current process information)
|
|
|
|
*/
|
|
|
|
static void backtrace_all(void)
|
|
|
|
{
|
2006-05-14 18:08:43 +02:00
|
|
|
struct dbg_process* process = dbg_curr_process;
|
2008-01-13 17:02:29 +01:00
|
|
|
struct dbg_thread* thread = dbg_curr_thread;
|
|
|
|
CONTEXT ctx = dbg_context;
|
|
|
|
DWORD cpid = dbg_curr_pid;
|
2005-05-29 22:03:56 +02:00
|
|
|
THREADENTRY32 entry;
|
|
|
|
HANDLE snapshot = CreateToolhelp32Snapshot(TH32CS_SNAPTHREAD, 0);
|
|
|
|
|
|
|
|
if (snapshot == INVALID_HANDLE_VALUE)
|
|
|
|
{
|
|
|
|
dbg_printf("Unable to create toolhelp snapshot\n");
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
entry.dwSize = sizeof(entry);
|
|
|
|
if (Thread32First(snapshot, &entry))
|
|
|
|
{
|
|
|
|
do
|
|
|
|
{
|
|
|
|
if (entry.th32OwnerProcessID == GetCurrentProcessId()) continue;
|
2008-01-13 17:02:29 +01:00
|
|
|
if (dbg_curr_process && dbg_curr_pid != entry.th32OwnerProcessID &&
|
|
|
|
cpid != dbg_curr_pid)
|
2006-02-27 21:50:43 +01:00
|
|
|
dbg_curr_process->process_io->close_process(dbg_curr_process, FALSE);
|
2005-05-29 22:03:56 +02:00
|
|
|
|
2008-01-13 17:02:29 +01:00
|
|
|
if (entry.th32OwnerProcessID == cpid)
|
|
|
|
{
|
|
|
|
dbg_curr_process = process;
|
|
|
|
dbg_curr_pid = cpid;
|
|
|
|
}
|
|
|
|
else if (entry.th32OwnerProcessID != dbg_curr_pid)
|
2005-05-29 22:03:56 +02:00
|
|
|
{
|
2006-09-25 22:45:24 +02:00
|
|
|
if (!dbg_attach_debuggee(entry.th32OwnerProcessID, FALSE))
|
2005-05-29 22:03:56 +02:00
|
|
|
{
|
2006-12-20 14:17:27 +01:00
|
|
|
dbg_printf("\nwarning: could not attach to %04x\n",
|
2005-05-29 22:03:56 +02:00
|
|
|
entry.th32OwnerProcessID);
|
|
|
|
continue;
|
|
|
|
}
|
|
|
|
dbg_curr_pid = dbg_curr_process->pid;
|
2006-09-25 22:45:24 +02:00
|
|
|
dbg_active_wait_for_first_exception();
|
2005-05-29 22:03:56 +02:00
|
|
|
}
|
|
|
|
|
2009-12-10 15:23:45 +01:00
|
|
|
dbg_printf("\nBacktracing for thread %04x in process %04lx (%s):\n",
|
2008-10-18 09:15:10 +02:00
|
|
|
entry.th32ThreadID, dbg_curr_pid,
|
|
|
|
dbg_W2A(dbg_curr_process->imageName, -1));
|
2005-11-18 13:33:03 +01:00
|
|
|
backtrace_tid(dbg_curr_process, entry.th32ThreadID);
|
2005-05-29 22:03:56 +02:00
|
|
|
}
|
|
|
|
while (Thread32Next(snapshot, &entry));
|
|
|
|
|
2008-01-13 17:02:29 +01:00
|
|
|
if (dbg_curr_process && cpid != dbg_curr_pid)
|
2006-02-27 21:50:43 +01:00
|
|
|
dbg_curr_process->process_io->close_process(dbg_curr_process, FALSE);
|
2005-05-29 22:03:56 +02:00
|
|
|
}
|
|
|
|
CloseHandle(snapshot);
|
2006-05-14 18:08:43 +02:00
|
|
|
dbg_curr_process = process;
|
2008-01-13 17:02:29 +01:00
|
|
|
dbg_curr_pid = cpid;
|
|
|
|
dbg_curr_thread = thread;
|
|
|
|
dbg_curr_tid = thread ? thread->tid : 0;
|
|
|
|
dbg_context = ctx;
|
2005-05-29 22:03:56 +02:00
|
|
|
}
|
|
|
|
|
2005-11-18 13:33:03 +01:00
|
|
|
void stack_backtrace(DWORD tid)
|
2005-05-29 22:03:56 +02:00
|
|
|
{
|
|
|
|
/* backtrace every thread in every process except the debugger itself,
|
|
|
|
* invoking via "bt all"
|
|
|
|
*/
|
|
|
|
if (tid == -1) return backtrace_all();
|
|
|
|
|
|
|
|
if (!dbg_curr_process)
|
|
|
|
{
|
|
|
|
dbg_printf("You must be attached to a process to run this command.\n");
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2004-06-04 02:59:16 +02:00
|
|
|
if (tid == dbg_curr_tid)
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
2005-11-18 13:33:03 +01:00
|
|
|
backtrace();
|
1996-12-22 19:27:48 +01:00
|
|
|
}
|
2004-06-04 02:59:16 +02:00
|
|
|
else
|
1996-12-22 19:27:48 +01:00
|
|
|
{
|
2005-11-18 13:33:03 +01:00
|
|
|
backtrace_tid(dbg_curr_process, tid);
|
1996-12-22 19:27:48 +01:00
|
|
|
}
|
|
|
|
}
|