http://bugs.winehq.org/show_bug.cgi?id=10249
Summary: Battlefield2/SafeDisc 4.x and Punkbuster services cause
lockup: child processes debugging misconception
Product: Wine
Version: CVS/GIT
Platform: PC
OS/Version: Linux
Status: UNCONFIRMED
Severity: major
Priority: P2
Component: wine-kernel
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: focht(a)gmx.net
Created an attachment (id=8876)
--> (http://bugs.winehq.org/attachment.cgi?id=8876)
WINEDEBUG=-all,+server,+tid,+loaddll,+seh wine ./BF2.exe +fullscreen 0 +szx 800
+szy 600 &>/tmp/debug_pipe
Hello,
while testing some PunkBuster stuff on popular games, I came across Battlefield
2 which employs SafeDisc 4.x
It seems there is a problem with debuggers in chained child processes.
Consider following scenario:
--- snip process list ---
pid threads parent executable (all id:s are in hex)
0000001b 1 00000008 'PnkBstrA.exe'
0000000c 2 00000008 'explorer.exe'
0000000a 2 00000008 '~e5.0001'
00000008 4 00000000 'BF2.exe'
--- snip process list ---
--- snip thread list ---
process tid prio (all id:s are in hex)
0000001b
0000001c 0
0000000c
00000010 0
0000000d 0
0000000a
00000012 0
0000000b 0
00000008
0000001a 1
00000014 15
00000013 0
00000009 0
--- snip thread list ---
"BF2.exe" = parent (game)
"~e5.0001" = 1st child = SafeDisc 4.x process = "debugger"
"PnkBstrA.exe" = 2nd child = PunkBuster Update Service
The 1st child acts as debugger for the parent "BF2.exe" and receives all debug
events (process, thread creation, dll load/unload...)
There are lots of breakpoint events triggered from parent.
This is part of SafeDisc 4.x and used for on-the-fly decryption of code
sections (child decrypts code of father).
When PunkBuster is initialized (loading of pbcl = client, pbag = agent), the
following services should get started: PnkBstrA.exe, PnkBstrB.exe and finally
the kmode driver PnkBstrK.exe
The service process "PnkBstrA.exe" is started from main process "BF2.exe"
(which is a debuggee itself).
No debug flags (DEBUG_PROCESS | DEBUG_ONLY_THIS_PROCESS) are specified in
process creation flags.
The debugger (child of parent, receives the process creation event) does not
make debugger_attach() to the newly created child process.
The child process seems to inherit the state of being a "debuggee": wine server
-> new_process -> set_process_debugger( process, parent->debugger );
The parent got its process->debugger from debugger_attach().
This leads to a problem in child process startup code:
"dlls/kernel32/process.c:start_process()" checks the PEB->BeingDebugged field
and if set, a system breakpoint is encountered before the entry code is called.
This breakpoint results in debug event - seen by debugger.
Unfortunately this event is _not_ expected by debugger because it didn't expect
another debuggee (child) to be created.
Ok, long story short solution: If you debug a process by attaching to an
already created process, you _must_ treat default debugging flags as if the
process has been created with DEBUG_ONLY_THIS_PROCESS, meaning that all childs
created by debuggee will NOT automagically become debuggees.
Short and (hopefully) acceptable patch snippet:
--- snip ---
diff --git a/server/debugger.c b/server/debugger.c
index a64a17a..c59f3a0 100644
--- a/server/debugger.c
+++ b/server/debugger.c
@@ -444,6 +444,7 @@ static int debugger_attach( struct process *process, struct
thread *debugger )
resume_process( process );
return 0;
}
+ process->create_flags |= DEBUG_ONLY_THIS_PROCESS;
return 1;
error:
--- snip ---
And yes, the patch (snippet) works as intended (tm) ;-)
Attached for sake of completeness is relevant server trace.
Search for "001c:trace:seh:raise_exception code=80000003 flags=0
addr=0x7b870ed8 " to the point where the entry system breakpoint is triggered.
Regards
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=9366
Summary: QuickTimePlayer 7.2.0.240 aborts on unimplemented
function gdiplus.dll.GdipCreateRegion
Product: Wine
Version: CVS
Platform: Other
URL: http://www.apple.com/quicktime/download/
OS/Version: other
Status: NEW
Keywords: download
Severity: enhancement
Priority: P2
Component: wine-gdiplus
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: dank(a)kegel.com
Quicktime player 7.2.0.240 requires Windows XP or higher,
so you have to run winecfg to set windows version before trying to install.
The app installs, but trying to start it fails with
wine: Call from 0x7ee1cf20 to unimplemented function
gdiplus.dll.GdipCreateRegion, aborting
Installing native gdiplus gets the app to start
and mostly run; I was able to watch a lunar lander
movie clip. (I wasn't able to quit the app, though! :-)
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=9860
Summary: GDIPlus Function
Product: Wine
Version: 0.9.46.
Platform: All
OS/Version: Windows XP
Status: UNCONFIRMED
Severity: enhancement
Priority: P2
Component: wine-gdiplus
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: gicgioc(a)tiscali.it
MSN 8.1 doesn't start because gdiplus:GdipImageSelectActiveFrame not
implemented
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=9869
Summary: Tornado 2.2.1: Unhandled exception code 80000003
Product: Wine
Version: CVS/GIT
Platform: PC
OS/Version: Linux
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: wine-msvcrt
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: nick.couchman(a)seakr.com
Whenever I try to run Wind River Tornado 2.2.1 on Wine I get the following
messages:
fixme:dbghelp_msc:pe_load_debug_directory This guy has FPO information
err:syslevel:_EnterSysLevel (0x7ee220e0, level 2): Holding 0x7ed0eda0, level 3.
Expect deadlock!
err:syslevel:_EnterSysLevel (0x7ee220e0, level 2): Holding 0x7ed0eda0, level 3.
Expect deadlock!
err:syslevel:_CheckNotSysLevel Holding lock 0x7ed0eda0 level 3
err:seh:raise_exception Unhandled exception code 80000003 flags 0 addr
0x7b8888c0
and the application completely crashes. I've attached a (gzipped) trace log
using "WINEDEBUG=+relay wine..." to run the application. I've also attached
the output from winedbg at the point where the program crashes. I will be
happy to provide more info if needed.
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=10136
Summary: WinMerge does not work with wine
Product: Wine
Version: 0.9.46.
Platform: PC
OS/Version: Windows 2000
Status: UNCONFIRMED
Severity: enhancement
Priority: P2
Component: wine-kernel
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: noragen(a)gmx.net
Created an attachment (id=8713)
--> (http://bugs.winehq.org/attachment.cgi?id=8713)
wine-winmerge-Error.log
attached a error log.
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=9370
Summary: coreftp crashes at startup
Product: Wine
Version: CVS
Platform: PC
URL: http://www.coreftp.com/
OS/Version: Linux
Status: NEW
Keywords: download
Severity: normal
Priority: P2
Component: wine-x11driver
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: thestig(a)google.com
Created an attachment (id=7666)
--> (http://bugs.winehq.org/attachment.cgi?id=7666)
backtrace
I tried out Coreftp LE 2.0. It installs fine, but crashes on startup after
showing a splash screen.
On the initial run, it asks whether to set coreftp as the default ftp client,
and whether to use notepad to view ascii files. I answered no to both.
I don't have a copy of Windows handy to make sure it works there.
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=9972
Summary: Catan: sound runs 2x fast then freezes game
Product: Wine
Version: 0.9.46.
Platform: PC
OS/Version: other
Status: UNCONFIRMED
Severity: normal
Priority: P1
Component: test
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: bsmeyer29(a)hotmail.com
Created an attachment (id=8484)
--> (http://bugs.winehq.org/attachment.cgi?id=8484)
report while running the game
When running catan under wine, the game starts up fine but the sound plays
twice as fast until it finishes playing through the first loop. It then plays
three times as fast until the game/wine just freezes and the music studders.
You can close the application window to make it quit.
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=9660
Summary: Microsoft Money 2001 crashes during install
Product: Wine
Version: 0.9.45.
Platform: PC
OS/Version: Linux
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: wine-misc
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: jonathan(a)xlcus.com
Created an attachment (id=8072)
--> (http://bugs.winehq.org/attachment.cgi?id=8072)
Microsoft Money 2001 crash log (Windows version selected: 2000)
On trying to install Microsoft Money 2001 (By running /msmoney/setup.exe from
CD 2 of Microsoft Works Suite 2001), Wine crashes part way through the
installer. See attached log. This is with a clean ~/.wine directory on Ubuntu
Feisty.
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=9906
Summary: Can't start the 4D Client
Product: Wine
Version: 0.9.46.
Platform: PC
URL: http://www.4d.com
OS/Version: Linux
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: wine-binary
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: roland(a)javalia.se
Created an attachment (id=8397)
--> (http://bugs.winehq.org/attachment.cgi?id=8397)
The backtrace when trying to run 4D Client 2004
4D 2004, installs well but doesn't run the application 4D client at all. Se
backtrace.
The application is in the AppDB if there are missing instructions about how to
make it run.
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=9740
Summary: Unimplemented function causes Phantasmagoria 2 to crash
Product: Wine
Version: 0.9.44.
Platform: PC
OS/Version: Linux
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: wine-msvcrt
AssignedTo: wine-bugs(a)winehq.org
ReportedBy: deadlock(a)start.no
Created an attachment (id=8178)
--> (http://bugs.winehq.org/attachment.cgi?id=8178)
Crash log, +relay, +msgbox
When I start Phantasmagoria 2 - A puzzle of flesh, it crashes because of an
unimplemented function.
It tries to call msvcrt40.dll.??0ostrstream@@QAE@PADHH@Z which appears to be
unimplemented. I have attached the log from the crash.
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.