[Bug 17539] New: NULL pointer dereference in Metrowerks Standard Library when CodeWarrior Pro 8.3 IDE launched with absolute pathname
wine-bugs at winehq.org
wine-bugs at winehq.org
Thu Feb 26 11:22:59 CST 2009
http://bugs.winehq.org/show_bug.cgi?id=17539
Summary: NULL pointer dereference in Metrowerks Standard Library
when CodeWarrior Pro 8.3 IDE launched with absolute
pathname
Product: Wine
Version: 1.1.4
Platform: PC-x86-64
URL: http://www.freescale.com/webapp/sps/site/homepage.jsp?no
deId=012726
OS/Version: Linux
Status: UNCONFIRMED
Severity: major
Priority: P1
Component: programs
AssignedTo: wine-bugs at winehq.org
ReportedBy: rippit at oggfrog.com
Created an attachment (id=19673)
--> (http://bugs.winehq.org/attachment.cgi?id=19673)
Crash Log.
First, let me say that I am *profoundly* impressed by how far Wine has come. I
tried CodeWarrior Pro 8.3 with Wine back in 2003 or so, and it didn't even come
close to working. Now it is completely usable; each of the three bugs I'll be
reporting has a workaround.
If Metrowerks CodeWarrior's IDE.exe is named on the Wine command line with an
absolute pathname, there will be a NULL pointer dereference in the Metrowerks
Standard Library DLL IDE_MSL_DLL80_x86.dll,
The crash is 100% repeatible with an absolute path, but never happens if the
IDE is launched with any kind of relative path. So the workaround it to never
use an absolute pathname.
The happy news is that the source code to the Metrowerks Standard Library is
included with CodeWarrior itself, though it's possible that the DLL that
IDE.exe links to has been patched somehow.
(The MSL is CodeWarrior's portable C and C++ standard libraries - apps built
with CodeWarrior don't normally use the ones bundled with the OS.)
The bad news is that CodeWarrior is no longer sold for building desktop
applications, just embedded ones. CodeWarrior Pro 8 is therefore hard to come
by, though it can sometimes be had used. Possibly you could reproduce the bug
with the free 30-day evaluation of FreeScale's Windows-hosted embedded
development system at the link above.
The old desktop tools publisher was Metrowerks; CodeWarrior Pro ran on both Mac
and Windows, and could produce binaries for both platforms while running on
either platform.
The following crashes every time:
wine "/home/mike/.wine/drive_c/Program Files/Metrowerks/CodeWarrior/IDE.exe"
But remove the initial slash, and it *works* every time:
cd /
wine "home/mike/.wine/drive_c/Program Files/Metrowerks/CodeWarrior/IDE.exe"
I discovered the crash by trying to write a double-clickable shell script for
use under Gnome in Fedora 10. The workaround is to use the following script
instead:
#!/bin/sh
DRIVE_C=~/.wine/drive_c
# Note that because the Program Files folder has a space in
# its name, it must be quoted.
PROGRAM_FILES="$DRIVE_C/Program Files"
( cd "$PROGRAM_FILES" ; \
/usr/bin/wine Metrowerks/CodeWarrior/Bin/IDE.exe )
My box is a Core Quad Xeon, a 5230 I think, running Fedora 10 x86_64 with 8 GB
of memory.
To set up CW 8.3, you'll need to install CW 8, then run the 8.2 and 8.3
updaters, then rebuild all the libraries. In more detail:
1. Make CD images of the two installation CDs - Windows Tools and Windows
Reference. I used the Mac OS X Disk Utility to make a CD/DVD Master image
(.cdr). I don't think it would work to make a compressed image (.dmg).
2. Create a directory that will be used as Wine's CD drive, then configure Wine
to actually use it as the CD drive. In Fedora 10, I use /media/WineD.
3. mount -o loop Tools.cdr /media/WineD
4. cd /media/WineD; wine Launch.exe
5. Do a full installation of the tools
6. umount /media/WineD
7. mount -o loop Reference.cdr /media/Wined
8. cd /media/WineD; wine Launch.exe
9. Do a full installation of the documentation
10. umount /media/WineD
11. Install the 8.2 and 8.3 updates:
12. wine CW_Pro8.2_Patch.exe
13. wine CW_Pro8.3_Patch.exe
14. After the 8.3 update, the Installer wants you to rebuild the libraries, and
offers to open the library rebuilding projects.
15. Project->Remove Object Code
16. Project->Make
After all that you'll be at the configuration with which I discovered the
crash.
--
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