[Bug 25305] King's Quest Collection Series (1997): setup.exe fails to add program group, then crashes

wine-bugs at winehq.org wine-bugs at winehq.org
Sat Nov 27 15:31:29 CST 2010


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

--- Comment #6 from Tristan Schmelcher <tristan_schmelcher at alumni.uwaterloo.ca> 2010-11-27 15:31:29 CST ---
I looked into the DdeCreateDataHandle failure and I think the problem is that
Wine should not attempt to validate the idInst argument. This installer calls
DdeInitialize at start-up, which succeeds and returns an idInst of 0x1, and the
installer correctly passes that value to several DDE calls right after (e.g.,
DdeCreateStringHandle). But when it (much later) calls DdeCreateDataHandle, it
passes an invalid idInst value of 0x112bf. Since idInst isn't actually needed
to execute the function, I think perhaps Windows does not validate it and this
installer relies on that behaviour ...

I tried commenting-out the idInst validation code in DdeCreateDataHandle and
with that change the call succeeds. Also, the following DdeClientTransaction
call gets farther because pData is no longer NULL ... but it fails at the
DdeAccessData call in WDML_ClientQueueExecute because pData is an invalid
pointer ... only the low order 16-bits of it are used, the upper half is zero.
So I think maybe DdeCreateDataHandle16 needs to map the created HDDEDATA into
the 16-bit address space so that the returned pointer can fit in the 16-bit
registers/fields used in the installer code. Possibly MapLS/MapSL can do this?

-- 
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