[Bug 22815] Alt.binz 0.28.5 gives access violation and fails to load settings at default 96 dpi setting (needs at least 101 dpi)

wine-bugs at winehq.org wine-bugs at winehq.org
Tue Jan 17 17:23:21 CST 2012


http://bugs.winehq.org/show_bug.cgi?id=22815

Anastasius Focht <focht at gmx.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |download
                URL|                            |http://proxy.nsanedown.com/
                   |                            |proxy.php?file=altbinz0285.
                   |                            |zip
                 CC|                            |focht at gmx.net
            Summary|Alt.binz 0.28.5 gives       |Alt.binz 0.28.5 gives
                   |access violation and fails  |access violation and fails
                   |to load settings.           |to load settings at default
                   |                            |96 dpi setting (needs at
                   |                            |least 101 dpi)

--- Comment #15 from Anastasius Focht <focht at gmx.net> 2012-01-17 17:23:21 CST ---
Hello,

confirming, still present.

--- snip ---
...
0024:Call
gdi32.CreateDIBSection(00000000,009ecc80,00000000,009eccac,00000000,00000000)
ret=0051cbac
0024:Ret  gdi32.CreateDIBSection() retval=000096a4 ret=0051cbac
0024:Call gdi32.CreateCompatibleDC(00000000) ret=0051cbd8
0024:Ret  gdi32.CreateCompatibleDC() retval=000096a8 ret=0051cbd8
0024:Call gdi32.SelectObject(000096a8,000096a4) ret=0051cc35
0024:Ret  gdi32.SelectObject() retval=0000006c ret=0051cc35
0024:trace:seh:raise_exception code=c0000005 flags=0 addr=0x519d0f ip=00519d0f
tid=0024
0024:trace:seh:raise_exception  info[0]=00000001
0024:trace:seh:raise_exception  info[1]=02732000
0024:trace:seh:raise_exception  eax=ff9ebef5 ebx=009ecc40 ecx=00000034
edx=00000062 esi=009f3284 edi=02732000
0024:trace:seh:raise_exception  ebp=00f5be9e esp=0032fadc cs=0023 ds=002b
es=002b fs=0063 gs=006b flags=00210202
0024:trace:seh:call_stack_handlers calling handler at 0x619a60 code=c0000005
flags=0
0024:trace:seh:call_stack_handlers handler at 0x619a60 returned 1
0024:trace:seh:call_stack_handlers calling handler at 0x61dbdf code=c0000005
flags=0
0024:trace:seh:call_stack_handlers handler at 0x61dbdf returned 1
0024:trace:seh:call_stack_handlers calling handler at 0x469085 code=c0000005
flags=0 
...
0024:Call user32.MessageBoxA(000100a0,01c3cfb4 "Access violation at address
00519D0F in module 'altbinz.exe'. Write of address 02732000.",009d2af8
"Alt.Binz 0.28.5",00000010) ret=004707b3
--- snip ---

>From another run using debugger:

32bpp BI_RGB DIB section, top-down (negative height)

--- snip ---
0033FA84  /00000000  ; |hDC = NULL
0033FA88  |009ECE24  ; |pBitmapInfo ! 009ECE24 -> BITMAPINFO {Size=40.,
Width=100., Height=-20., Planes=1, BitCount=32., Compression=BI_RGB,
SizeImage=0, XPelsPerMeter=0, YPelsPerMeter=0, ColorsUsed=0, ColorsImportant=0}
0033FA8C  |00000000  ; |Usage = DIB_RGB_COLORS
0033FA90  |009ECE50  ; |ppBits = 009ECE50 -> NULL
0033FA94  |00000000  ; |hSection = NULL
0033FA98  |00000000  ; \Offset = 0
--- snip ---

*ppBits -> 02720000

100*20*4 -> 8000 (8K rounded -> 0x2000)

Memory view:

--- snip ---
...
026E0000  00001000  unrar             PE header    Img  R        RWE Copy
026E1000  00023000  unrar  .text      Code         Img  R E      RWE Copy
02704000  0000E000  unrar  .data      Data         Img  RW  Copy>RWE Copy
02712000  00001000  unrar  .tls                    Img  RW  Copy>RWE Copy
02713000  00001000  unrar  .idata     Imports      Img  R        RWE Copy
02714000  00001000  unrar  .edata     Exports      Img  R        RWE Copy
02715000  00001000  unrar  .rsrc      Resources    Img  R        RWE Copy
02716000  00002000  unrar  .reloc     Relocations  Img  R        RWE Copy
02720000  00002000                                 Priv RW       RW
02820000  00001000                                 Priv RW       RW
02830000  00001000                                 Priv RW       RW
...
--- snip ---

You can verify the reported font height vs. DIB allocation size by changing
default 96 dpi to larger values.
At 101 dpi the app stops crashing at startup and works fine.

The location where the previous crash happened now looks like this:

--- snip ---
...
0024:Call
gdi32.CreateDIBSection(00000000,01c55814,00000000,01c55840,00000000,00000000)
ret=0051cbac
0024:Ret  gdi32.CreateDIBSection() retval=0000a288 ret=0051cbac
0024:Call gdi32.CreateCompatibleDC(00000000) ret=0051cbd8
0024:Ret  gdi32.CreateCompatibleDC() retval=0000a28c ret=0051cbd8
0024:Call gdi32.SelectObject(0000a28c,0000a288) ret=0051cc35
0024:Ret  gdi32.SelectObject() retval=0000006c ret=0051cc35
0024:Call gdi32.SelectObject(0000a28c,000079c0) ret=0051e87f
0024:Ret  gdi32.SelectObject() retval=0000007c ret=0051e87f
0024:Call gdi32.SetTextColor(0000a28c,00000000) ret=0051e897
0024:Ret  gdi32.SetTextColor() retval=00000000 ret=0051e897
0024:Call gdi32.SetBkMode(0000a28c,00000001) ret=0051e8a5
0024:Ret  gdi32.SetBkMode() retval=00000002 ret=0051e8a5
0024:Call user32.DrawTextA(0000a28c,01c5eca0 "0.00
MB",00000007,0032fac8,00008025) ret=0051e965
0024:Ret  user32.DrawTextA() retval=00000010 ret=0051e965
0024:Call comctl32.InitCommonControlsEx(0032f984) ret=004311e5
0024:Ret  comctl32.InitCommonControlsEx() retval=00000001 ret=004311e5
0024:Call user32.LoadCursorA(00000000,00007f00) ret=00452da2
0024:Ret  user32.LoadCursorA() retval=0002002c ret=00452da2
0024:Call user32.GetClassInfoA(00400000,0032fa34 "TMyStatusbar",0032f9c0)
ret=00452ec5
0024:Ret  user32.GetClassInfoA() retval=0000c06e ret=00452ec5
0024:Call user32.CreateWindowExA(00010000,0032fa34 "TMyStatusbar",009925dc
"",46000100,00000000,00000225,00000318,00000018,000100b0,00000000,00400000,00000000)
ret=004085ec
0024:trace:win:WIN_CreateWindowEx "" L"TMyStatusbar" ex=00010000 style=46000100
0,549 792x24 parent=0x100b0 menu=(nil) inst=0x400000 params=(nil)
0024:trace:win:dump_window_styles style: WS_CHILD WS_CLIPSIBLINGS
WS_CLIPCHILDREN 00000100
0024:trace:win:dump_window_styles exstyle: WS_EX_CONTROLPARENT
0024:trace:win:WIN_SetWindowLong 0x102a2 -12 0 W
0024:Call hook proc 0x57d724 (id=WH_CBT,code=3,wp=000102a2,lp=0032f538)
0024:Call user32.CallNextHookEx(000100be,00000003,000102a2,0032ef78)
ret=0057d7d1
0024:Ret  user32.CallNextHookEx() retval=00000000 ret=0057d7d1
0024:Ret  hook proc 0x57d724 (id=WH_CBT,code=3,wp=000102a2,lp=0032f538)
retval=00000000
0024:trace:win:GetWindowRect hwnd 0x102a2 (64,630)-(856,654)
0024:trace:win:invalidate_dce 0x102a2 scope hwnd = 0x100b0 (64,630)-(856,654)
((64,81)-(64,81))
0
...
0024:Call gdi32.SelectObject(0000a28c,0000007c) ret=0051e847
0024:Ret  gdi32.SelectObject() retval=000079c0 ret=0051e847
0024:Call gdi32.DeleteDC(0000a28c) ret=0051cb3b
0024:Ret  gdi32.DeleteDC() retval=00000001 ret=0051cb3b
0024:Call gdi32.DeleteObject(0000a288) ret=0051cb56
0024:Ret  gdi32.DeleteObject() retval=00000001 ret=0051cb56 
--- snip ---

That string "0.00 MB" ought to be drawn in a status bar strip.
If you place a breakpoint in gdi32.CreateDIBSection() entry you can see the
regions painted individually (make sure you don't overlap the client area with
terminal).

At 101 dpi the DIB height is (-)24 pix.
Maybe there is some minimum height expected (app bug) which worked previously
because of larger reported font height.
It would be interesting to know the height of that status bar strip in Windows
(at default 96 dpi).

$ sha1sum altbinz0285.zip 
7fa3bb99db1bca0b0ee3e0c00e4f3a016ac14723  altbinz0285.zip

$ wine --version
wine-1.3.37-66-g6d391df

Regards

-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
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