James Hawkins wrote:
Auto = '1' Debugger = 'winedbg --auto %ld %ld'
does the attached patch help ?
[WineDbg]: fixed the auto mode
From: Eric Pouech eric.pouech@wanadoo.fr
---
programs/winedbg/info.c | 2 +- programs/winedbg/tgt_active.c | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/programs/winedbg/info.c b/programs/winedbg/info.c index d2042bf..c5b7b1e 100644 --- a/programs/winedbg/info.c +++ b/programs/winedbg/info.c @@ -204,7 +204,7 @@ void info_win32_module(DWORD base) int i, j, num_printed = 0; DWORD opt;
- if (!dbg_curr_process || !dbg_curr_thread) + if (!dbg_curr_process) { dbg_printf("Cannot get info on module while no process is loaded\n"); return; diff --git a/programs/winedbg/tgt_active.c b/programs/winedbg/tgt_active.c index af619a0..48f1ec9 100644 --- a/programs/winedbg/tgt_active.c +++ b/programs/winedbg/tgt_active.c @@ -867,7 +867,8 @@ enum dbg_start dbg_active_auto(int argc, argc--; argv++; ds = dbg_active_attach(argc, argv); if (ds != start_ok) return ds; - hFile = parser_generate_command_file("echo Modules:", "info share", + hFile = parser_generate_command_file("backtrace", + "echo Modules:", "info share", "echo Threads:", "info threads", NULL); } @@ -923,6 +924,9 @@ enum dbg_start dbg_active_auto(int argc, else return start_error_parse; if (hFile == INVALID_HANDLE_VALUE) return start_error_parse;
+ if (dbg_curr_process->active_debuggee) + dbg_active_wait_for_first_exception(); + dbg_interactiveP = TRUE; parser_handle(hFile);