[Bug 2835] can not start windows programs

Wine Bugs wine-bugs at winehq.org
Mon Apr 4 19:42:13 CDT 2005


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





------- Additional Comments From vberon at mecano.gme.usherb.ca  2005-04-04 19:42 -------
It looks like a problem in the mptrack.exe file.

Short rundown: the SizeOfRawData part of the .rsrc section was wrong (0x00043004
instead of 0x00043000). That caused the assertion failing when trying to map
that section of the file in memory.

Quick workaround: with a hex editor, modify byte 0x2e8 from 0x04 to 0x00. The
faulty byte was at the same address in two mptrack.exe files I could find,
although yours could be different. Then it should launch correctly (it does
here, although I haven't tried other buttons than Close).

Please report if that solution works for you. I don't think I can come up with a
proper fix for now, for reasons explained below.

Longer rundown: the file had a bad SizeOfRawData in one of the section headers:
it was bigger than it's VirtualSize rounded up to the next FileAlignment. Second
problem was that VirtualAddress+(bad)SizeOfRawData was higher than SizeOfImage.
That triggers the assertion. The VirtualSize value looks sane, but some docs on
the PE format say it's not always correctly set by all compilers, so we can't
blindly correct SizeOfRawData to
((VirtualSize+(FileAlignment-1))/FileAlignment)*FileAlignment or some such.

Any thoughts?

-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the wine-bugs mailing list