[Bug 35930] New: Crash handlers/debuggers fail to output diagnostics to console when invoked for crashing (non-interactive) service processes (handle inheritance)

wine-bugs at winehq.org wine-bugs at winehq.org
Sat Apr 5 12:51:28 CDT 2014


https://bugs.winehq.org/show_bug.cgi?id=35930

            Bug ID: 35930
           Summary: Crash handlers/debuggers fail to output diagnostics to
                    console when invoked for crashing (non-interactive)
                    service processes (handle inheritance)
           Product: Wine
           Version: 1.7.16
          Hardware: x86
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: -unknown
          Assignee: wine-bugs at winehq.org
          Reporter: focht at gmx.net

Hello folks,

bug 35924 is about a crash in a win32 service which triggers 'winedbg'
just-in-time debugger/crash handler.
Unfortunately 'winedbg' neither can bring up its user interface nor output the
backtrace to console.

The user-interface part is covered by bug 35928

Bootstrapping:

--- snip ---
wineserver: starting (pid=28494)
0008: *fd* 01c6 -> 20
0009: *fd* 6 <- 20
0009: *fd* 8 <- 21
0009: init_thread( unix_pid=28491, unix_tid=28491, debug_level=1, teb=7ffd8000,
entry=7ffdf000, reply_fd=6, wait_fd=8, cpu=x86 )
0009: init_thread() = 0 { pid=0008, tid=0009, server_start=1cf50cde49be514
(-0.0002420), info_size=0, version=454, all_cpus=00000001 }
0009: *fd* 1 <- 22
0009: alloc_file_handle( access=40100000, attributes=00000002, fd=1 )
0009: alloc_file_handle() = 0 { handle=0004 }
0009: *fd* 2 <- 23
0009: alloc_file_handle( access=40100000, attributes=00000002, fd=2 )
0009: alloc_file_handle() = 0 { handle=0008 }
--- snip ---

Service manager process creation:

--- snip ---
000b: new_process( inherit_all=1, create_flags=00000008, socket_fd=11,
exe_file=0024, process_access=001fffff, process_attr=00000000,
thread_access=001fffff, thread_attr=00000000, cpu=x86, info_size=558,
info={debug_flags=0,console_flags=0,console=0000,hstdin=ffffffff,hstdout=ffffffff,hstderr=0004,x=0,y=0,xsize=0,ysize=0,xchars=0,ychars=0,attribute=00,flags=0,show=0,curdir=L"C:\\windows\\",dllpath=L"C:\\windows\\system32;.;C:\\windows\\system32;C:\\windows\\system;C:\\windows;C:\\windows\\system32;C:\\windows;C:\\windows\\system32\\wbem",imagepath=L"C:\\windows\\system32\\services.exe",cmdline=L"C:\\windows\\system32\\services.exe",title=L"C:\\windows\\system32\\services.exe",desktop=L"",shellinfo=L"",runtime=L""},...)
000b: *fd* 01c6 -> 39
000b: new_process() = 0 { info=0028, pid=000e, phandle=002c, tid=000f,
thandle=0030 } 
...
000f: init_thread( unix_pid=28502, unix_tid=28502, debug_level=1, teb=7ffd8000,
entry=7ffdf000, reply_fd=5, wait_fd=7, cpu=x86 )
000f: init_thread() = 0 { pid=000e, tid=000f, server_start=1cf50cde49be514
(-0.0544480), info_size=8718, version=454, all_cpus=00000001 }
000f: get_startup_info( )
000f: get_startup_info() = 0 { exe_file=0008, info_size=558,
info={debug_flags=0,console_flags=0,console=0000,hstdin=ffffffff,hstdout=ffffffff,hstderr=0004,x=0,y=0,xsize=0,ysize=0,xchars=0,ychars=0,attribute=00,flags=0,show=0,curdir=L"C:\\windows\\",dllpath=L"C:\\windows\\system32;.;C:\\windows\\system32;C:\\windows\\system;C:\\windows;C:\\windows\\system32;C:\\windows;C:\\windows\\system32\\wbem",imagepath=L"C:\\windows\\system32\\services.exe",cmdline=L"C:\\windows\\system32\\services.exe",title=L"C:\\windows\\system32\\services.exe",desktop=L"",shellinfo=L"",runtime=L""},...
}
000f: create_keyed_event( access=c0000000, attributes=00000000,
objattr={rootdir=0000,sd={},name=L""} )
000f: create_keyed_event() = 0 { handle=000c } 
--- snip ---

Win32 service creation:

--- snip ---
0043: new_process( inherit_all=0, create_flags=00000400, socket_fd=41,
exe_file=00f4, process_access=001fffff, process_attr=00000000,
thread_access=001fffff, thread_attr=00000000, cpu=x86, info_size=844,
info={debug_flags=0,console_flags=0,console=0000,hstdin=ffffffff,hstdout=ffffffff,hstderr=0004,x=0,y=0,xsize=0,ysize=0,xchars=0,ychars=0,attribute=00,flags=0,show=0,curdir=L"C:\\windows\\",dllpath=L"C:\\windows\\system32;.;C:\\windows\\system32;C:\\windows\\system;C:\\windows;C:\\windows\\system32;C:\\windows;C:\\windows\\system32\\wbem",imagepath=L"C:\\Program
Files\\Echobit\\Evolve\\EvoSvc.exe",cmdline=L"\"C:\\Program
Files\\Echobit\\Evolve\\EvoSvc.exe\" -service -logfile
\"C:\\users\\Public\\Application
Data\\Echobit\\Evolve\\EvoSvc.log\"",title=L"C:\\Program
Files\\Echobit\\Evolve\\EvoSvc.exe",desktop=L"__wineservice_winstation\\Default",shellinfo=L"",runtime=L""},
... )
0043: *fd* 01c6 -> 232
0043: new_process() = 0 { info=00f8, pid=0044, phandle=00fc, tid=0045,
thandle=0100 } 
...
--- snip ---

Winedbg spawned from crashing service:

--- snip ---
...
0045: new_process( inherit_all=1, create_flags=00000400, socket_fd=12,
exe_file=0088, process_access=001fffff, process_attr=00000000,
thread_access=001fffff, thread_attr=00000000, cpu=x86, info_size=556,
info={debug_flags=0,console_flags=0,console=0000,hstdin=0004,hstdout=0008,hstderr=000c,x=0,y=0,xsize=0,ysize=0,xchars=0,ychars=0,attribute=00,flags=1,show=1,curdir=L"C:\\windows\\",dllpath=L"C:\\Program
Files\\Echobit\\Evolve;.;C:\\windows\\system32;C:\\windows\\system;C:\\windows;C:\\windows\\system32;C:\\windows;C:\\windows\\system32\\wbem",imagepath=L"C:\\windows\\system32\\winedbg.exe",cmdline=L"winedbg
--auto 68
132",title=L"C:\\windows\\system32\\winedbg.exe",desktop=L"",shellinfo=L"",runtime=L""},
...
0045: *fd* 01c6 -> 239
0045: new_process() = 0 { info=008c, pid=0046, phandle=0090, tid=0047,
thandle=0094 } 
...
--- snip ---

--- snip ---
...
0045: get_handle_fd( handle=0004 )
0045: get_handle_fd() = OBJECT_TYPE_MISMATCH { type=0, cacheable=0,
access=00000000, options=00000000 }
0045: get_handle_fd( handle=0008 )
0045: get_handle_fd() = OBJECT_TYPE_MISMATCH { type=0, cacheable=0,
access=00000000, options=00000000 } 
...
0047: get_startup_info( )
0047: get_startup_info() = 0 { exe_file=0018, info_size=556,
info={debug_flags=0,console_flags=0,console=0000,hstdin=0004,hstdout=0008,hstderr=000c,x=0,y=0,xsize=0,ysize=0,xchars=0,ychars=0,attribute=00,flags=1,show=1,curdir=L"C:\\windows\\",dllpath=L"C:\\Program
Files\\Echobit\\Evolve;.;C:\\windows\\system32;C:\\windows\\system;C:\\windows;C:\\windows\\system32;C:\\windows;C:\\windows\\system32\\wbem",imagepath=L"C:\\windows\\system32\\winedbg.exe",cmdline=L"winedbg
--auto 68
132",title=L"C:\\windows\\system32\\winedbg.exe",desktop=L"",shellinfo=L"",runtime=L""},
...
...
0047:Call KERNEL32.GetStdHandle(fffffff5) ret=7edc95e2
0047:Ret  KERNEL32.GetStdHandle() retval=00000008 ret=7edc95e2
0047:Call KERNEL32.SetConsoleCtrlHandler(7edc9599,00000001) ret=7edc9603
0047:Ret  KERNEL32.SetConsoleCtrlHandler() retval=00000001 ret=7edc9603
0047:Call KERNEL32.SetConsoleTitleA(7edd5ba8 "Wine Debugger") ret=7edc9614
0047: get_console_input_info( handle=0000 )
0047: get_console_input_info() = INVALID_PARAMETER { history_mode=0,
history_size=0, history_index=0, edition_mode=0, input_cp=0, output_cp=0,
win=00000000, title=L"" }
0047: get_console_input_info( handle=0000 )
0047: get_console_input_info() = INVALID_PARAMETER { history_mode=0,
history_size=0, history_index=0, edition_mode=0, input_cp=0, output_cp=0,
win=00000000, title=L"" }
0047: set_console_input_info( handle=0000, mask=2, active_sb=0000,
history_mode=0, history_size=0, edition_mode=0, input_cp=0, output_cp=0,
win=00000000, title=L"Wine Debugger" )
0047: set_console_input_info() = INVALID_PARAMETER
0047:Ret  KERNEL32.SetConsoleTitleA() retval=00000000 ret=7edc9614 
...
0047:trace:winedbg:dbg_handle_exception exception=c0000005 first_chance=N
0047:Call KERNEL32.WriteFile(00000008,7edfd800,0000005a,0033f754,00000000)
ret=7edc80a4
0047:trace:file:WriteFile 0x8 0x7edfd800 90 0x33f754 (nil)
0047:trace:ntdll:NtWriteFile
(0x8,(nil),(nil),(nil),0x33f690,0x7edfd800,0x0000005a,(nil),(nil))!
0047: get_handle_fd( handle=0008 )
0047: get_handle_fd() = OBJECT_TYPE_MISMATCH { type=0, cacheable=0,
access=00000000, options=00000000 }
0047:Ret  KERNEL32.WriteFile() retval=00000000 ret=7edc80a4 
--- snip ---

$ sha1sum EvolveSetup.exe 
0c9f92f1ed5f97bced68c1185525dfe78900f795  EvolveSetup.exe

$ du -sh EvolveSetup.exe 
3.2M    EvolveSetup.exe

$ wine --version
wine-1.7.16

Regards

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list