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
069897ad
Commit
069897ad
authored
Aug 27, 2018
by
Alistair Leslie-Hughes
Committed by
Alexandre Julliard
Aug 27, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dpnet: Implement IDirectPlay8Peer SetSPCaps.
Signed-off-by:
Alistair Leslie-Hughes
<
leslie_alistair@hotmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
f6bd24fd
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
35 additions
and
2 deletions
+35
-2
peer.c
dlls/dpnet/peer.c
+10
-2
client.c
dlls/dpnet/tests/client.c
+25
-0
No files found.
dlls/dpnet/peer.c
View file @
069897ad
...
@@ -526,9 +526,17 @@ static HRESULT WINAPI IDirectPlay8PeerImpl_SetCaps(IDirectPlay8Peer *iface, cons
...
@@ -526,9 +526,17 @@ static HRESULT WINAPI IDirectPlay8PeerImpl_SetCaps(IDirectPlay8Peer *iface, cons
static
HRESULT
WINAPI
IDirectPlay8PeerImpl_SetSPCaps
(
IDirectPlay8Peer
*
iface
,
const
GUID
*
const
pguidSP
,
static
HRESULT
WINAPI
IDirectPlay8PeerImpl_SetSPCaps
(
IDirectPlay8Peer
*
iface
,
const
GUID
*
const
pguidSP
,
const
DPN_SP_CAPS
*
const
pdpspCaps
,
const
DWORD
dwFlags
)
const
DPN_SP_CAPS
*
const
pdpspCaps
,
const
DWORD
dwFlags
)
{
{
FIXME
(
"(%p)->(%p,%p,%x): stub
\n
"
,
iface
,
pguidSP
,
pdpspCaps
,
dwFlags
);
IDirectPlay8PeerImpl
*
This
=
impl_from_IDirectPlay8Peer
(
iface
);
return
DPNERR_GENERIC
;
TRACE
(
"(%p)->(%p,%p,%x): stub
\n
"
,
iface
,
pguidSP
,
pdpspCaps
,
dwFlags
);
if
(
!
This
->
msghandler
||
pdpspCaps
->
dwSize
!=
sizeof
(
DPN_SP_CAPS
))
return
DPNERR_INVALIDPARAM
;
/* Only dwSystemBufferSize is set by this call. */
This
->
spcaps
.
dwSystemBufferSize
=
pdpspCaps
->
dwSystemBufferSize
;
return
DPN_OK
;
}
}
static
HRESULT
WINAPI
IDirectPlay8PeerImpl_GetSPCaps
(
IDirectPlay8Peer
*
iface
,
const
GUID
*
const
pguidSP
,
static
HRESULT
WINAPI
IDirectPlay8PeerImpl_GetSPCaps
(
IDirectPlay8Peer
*
iface
,
const
GUID
*
const
pguidSP
,
...
...
dlls/dpnet/tests/client.c
View file @
069897ad
...
@@ -561,6 +561,9 @@ static void test_init_dp_peer(void)
...
@@ -561,6 +561,9 @@ static void test_init_dp_peer(void)
memset
(
&
caps
,
0
,
sizeof
(
DPN_SP_CAPS
));
memset
(
&
caps
,
0
,
sizeof
(
DPN_SP_CAPS
));
caps
.
dwSize
=
sizeof
(
DPN_SP_CAPS
);
caps
.
dwSize
=
sizeof
(
DPN_SP_CAPS
);
hr
=
IDirectPlay8Peer_SetSPCaps
(
peer
,
&
CLSID_DP8SP_TCPIP
,
&
caps
,
0
);
ok
(
hr
==
DPNERR_INVALIDPARAM
,
"SetSPCaps failed with %x
\n
"
,
hr
);
hr
=
IDirectPlay8Peer_GetSPCaps
(
peer
,
&
CLSID_DP8SP_TCPIP
,
&
caps
,
0
);
hr
=
IDirectPlay8Peer_GetSPCaps
(
peer
,
&
CLSID_DP8SP_TCPIP
,
&
caps
,
0
);
ok
(
hr
==
DPNERR_UNINITIALIZED
,
"GetSPCaps failed with %x
\n
"
,
hr
);
ok
(
hr
==
DPNERR_UNINITIALIZED
,
"GetSPCaps failed with %x
\n
"
,
hr
);
...
@@ -815,6 +818,28 @@ static void test_get_sp_caps_peer(void)
...
@@ -815,6 +818,28 @@ static void test_get_sp_caps_peer(void)
ok
(
caps
.
dwBuffersPerThread
==
1
,
"expected 1, got %d
\n
"
,
caps
.
dwBuffersPerThread
);
ok
(
caps
.
dwBuffersPerThread
==
1
,
"expected 1, got %d
\n
"
,
caps
.
dwBuffersPerThread
);
ok
(
caps
.
dwSystemBufferSize
==
0x10000
||
broken
(
caps
.
dwSystemBufferSize
==
0x2000
/* before Win8 */
),
ok
(
caps
.
dwSystemBufferSize
==
0x10000
||
broken
(
caps
.
dwSystemBufferSize
==
0x2000
/* before Win8 */
),
"expected 0x10000, got 0x%x
\n
"
,
caps
.
dwSystemBufferSize
);
"expected 0x10000, got 0x%x
\n
"
,
caps
.
dwSystemBufferSize
);
caps
.
dwNumThreads
=
2
;
caps
.
dwDefaultEnumCount
=
3
;
caps
.
dwDefaultEnumRetryInterval
=
1400
;
caps
.
dwDefaultEnumTimeout
=
1400
;
caps
.
dwMaxEnumPayloadSize
=
900
;
caps
.
dwBuffersPerThread
=
2
;
caps
.
dwSystemBufferSize
=
0x0ffff
;
hr
=
IDirectPlay8Peer_SetSPCaps
(
peer
,
&
CLSID_DP8SP_TCPIP
,
&
caps
,
0
);
ok
(
hr
==
DPN_OK
,
"SetSPCaps failed with %x
\n
"
,
hr
);
hr
=
IDirectPlay8Peer_GetSPCaps
(
peer
,
&
CLSID_DP8SP_TCPIP
,
&
caps
,
0
);
ok
(
hr
==
DPN_OK
,
"GetSPCaps failed with %x
\n
"
,
hr
);
ok
(
caps
.
dwSize
==
sizeof
(
DPN_SP_CAPS
),
"got %d
\n
"
,
caps
.
dwSize
);
ok
(
caps
.
dwNumThreads
>=
3
,
"got %d
\n
"
,
caps
.
dwNumThreads
);
ok
(
caps
.
dwDefaultEnumCount
==
5
,
"expected 5, got %d
\n
"
,
caps
.
dwDefaultEnumCount
);
ok
(
caps
.
dwDefaultEnumRetryInterval
==
1500
,
"expected 1500, got %d
\n
"
,
caps
.
dwDefaultEnumRetryInterval
);
ok
(
caps
.
dwDefaultEnumTimeout
==
1500
,
"expected 1500, got %d
\n
"
,
caps
.
dwDefaultEnumTimeout
);
ok
(
caps
.
dwMaxEnumPayloadSize
==
983
,
"expected 983, got %d
\n
"
,
caps
.
dwMaxEnumPayloadSize
);
ok
(
caps
.
dwBuffersPerThread
==
1
,
"expected 1, got %d
\n
"
,
caps
.
dwBuffersPerThread
);
ok
(
caps
.
dwSystemBufferSize
==
0x0ffff
,
"expected 0x0ffff, got 0x%x
\n
"
,
caps
.
dwSystemBufferSize
);
}
}
static
void
test_player_info_peer
(
void
)
static
void
test_player_info_peer
(
void
)
...
...
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