Tristan Schmelcher tristan_schmelcher@alumni.uwaterloo.ca wrote:
- if (cbData != (DWORD)-1)
- {
/* pData is not a pointer if cbData is -1, so we linearize the address
* here rather than in the calling code. */
pData = MapSL((SEGPTR)pData);
- }
-1 here should be replaced by CBR_BLOCK, and this piece of the patch should be sent separately from .spec file fixes.
I think CBR_BLOCK is only for values of type HDDEDATA. The cbData value here is a DWORD (specifying a length). (DWORD)-1 seems to be the preferred way of checking this condition in the existing code, e.g. see dlls/user32/dde_client.c lines 637, 648, etc.
I will re-send the patch in two parts.
On Thu, Dec 2, 2010 at 12:19 AM, Dmitry Timoshkov dmitry@codeweavers.com wrote:
Tristan Schmelcher tristan_schmelcher@alumni.uwaterloo.ca wrote:
- if (cbData != (DWORD)-1)
- {
- /* pData is not a pointer if cbData is -1, so we linearize the address
- * here rather than in the calling code. */
- pData = MapSL((SEGPTR)pData);
- }
-1 here should be replaced by CBR_BLOCK, and this piece of the patch should be sent separately from .spec file fixes.
-- Dmitry.
Tristan Schmelcher tristan_schmelcher@alumni.uwaterloo.ca wrote:
I think CBR_BLOCK is only for values of type HDDEDATA. The cbData value here is a DWORD (specifying a length). (DWORD)-1 seems to be the preferred way of checking this condition in the existing code, e.g. see dlls/user32/dde_client.c lines 637, 648, etc.
You are right.