Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
9c6494a4
Commit
9c6494a4
authored
Jan 10, 2009
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32: The PackDDElParam return value is sign-extended on 64-bit.
parent
9cc75a5b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
6 deletions
+7
-6
dde_misc.c
dlls/user32/dde_misc.c
+1
-1
dde.c
dlls/user32/tests/dde.c
+6
-5
No files found.
dlls/user32/dde_misc.c
View file @
9c6494a4
...
...
@@ -103,7 +103,7 @@ LPARAM WINAPI PackDDElParam(UINT msg, UINT_PTR uiLo, UINT_PTR uiHi)
return
uiHi
;
default:
return
MAKEL
PARAM
(
uiLo
,
uiHi
);
return
MAKEL
ONG
(
uiLo
,
uiHi
);
}
}
...
...
dlls/user32/tests/dde.c
View file @
9c6494a4
...
...
@@ -1793,7 +1793,8 @@ static void test_PackDDElParam(void)
BOOL
ret
;
lparam
=
PackDDElParam
(
WM_DDE_INITIATE
,
0xcafe
,
0xbeef
);
ok
(
lparam
==
0xbeefcafe
,
"Expected 0xbeefcafe, got %08lx
\n
"
,
lparam
);
/* value gets sign-extended despite being an LPARAM */
ok
(
lparam
==
(
int
)
0xbeefcafe
,
"Expected 0xbeefcafe, got %08lx
\n
"
,
lparam
);
ok
(
GlobalLock
((
HGLOBAL
)
lparam
)
==
NULL
,
"Expected NULL, got %p
\n
"
,
GlobalLock
((
HGLOBAL
)
lparam
));
ok
(
GetLastError
()
==
ERROR_INVALID_HANDLE
,
...
...
@@ -1809,7 +1810,7 @@ static void test_PackDDElParam(void)
ok
(
ret
==
TRUE
,
"Expected TRUE, got %d
\n
"
,
ret
);
lparam
=
PackDDElParam
(
WM_DDE_TERMINATE
,
0xcafe
,
0xbeef
);
ok
(
lparam
==
0xbeefcafe
,
"Expected 0xbeefcafe, got %08lx
\n
"
,
lparam
);
ok
(
lparam
==
(
int
)
0xbeefcafe
,
"Expected 0xbeefcafe, got %08lx
\n
"
,
lparam
);
ok
(
GlobalLock
((
HGLOBAL
)
lparam
)
==
NULL
,
"Expected NULL, got %p
\n
"
,
GlobalLock
((
HGLOBAL
)
lparam
));
ok
(
GetLastError
()
==
ERROR_INVALID_HANDLE
,
...
...
@@ -1853,7 +1854,7 @@ static void test_PackDDElParam(void)
"Expected ERROR_INVALID_HANDLE, got %d
\n
"
,
GetLastError
());
lparam
=
PackDDElParam
(
WM_DDE_UNADVISE
,
0xcafe
,
0xbeef
);
ok
(
lparam
==
0xbeefcafe
,
"Expected 0xbeefcafe, got %08lx
\n
"
,
lparam
);
ok
(
lparam
==
(
int
)
0xbeefcafe
,
"Expected 0xbeefcafe, got %08lx
\n
"
,
lparam
);
ok
(
GlobalLock
((
HGLOBAL
)
lparam
)
==
NULL
,
"Expected NULL, got %p
\n
"
,
GlobalLock
((
HGLOBAL
)
lparam
));
ok
(
GetLastError
()
==
ERROR_INVALID_HANDLE
,
...
...
@@ -1870,7 +1871,7 @@ static void test_PackDDElParam(void)
lparam
=
PackDDElParam
(
WM_DDE_ACK
,
0xcafe
,
0xbeef
);
/* win9x returns the input (0xbeef<<16 | 0xcafe) here */
if
(
lparam
!=
0xbeefcafe
)
{
if
(
lparam
!=
(
int
)
0xbeefcafe
)
{
ptr
=
GlobalLock
((
HGLOBAL
)
lparam
);
ok
(
ptr
!=
NULL
,
"Expected non-NULL ptr
\n
"
);
ok
(
ptr
[
0
]
==
0xcafe
,
"Expected 0xcafe, got %08lx
\n
"
,
ptr
[
0
]);
...
...
@@ -1925,7 +1926,7 @@ static void test_PackDDElParam(void)
"Expected ERROR_INVALID_HANDLE, got %d
\n
"
,
GetLastError
());
lparam
=
PackDDElParam
(
WM_DDE_REQUEST
,
0xcafe
,
0xbeef
);
ok
(
lparam
==
0xbeefcafe
,
"Expected 0xbeefcafe, got %08lx
\n
"
,
lparam
);
ok
(
lparam
==
(
int
)
0xbeefcafe
,
"Expected 0xbeefcafe, got %08lx
\n
"
,
lparam
);
ok
(
GlobalLock
((
HGLOBAL
)
lparam
)
==
NULL
,
"Expected NULL, got %p
\n
"
,
GlobalLock
((
HGLOBAL
)
lparam
));
ok
(
GetLastError
()
==
ERROR_INVALID_HANDLE
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment