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
ec7c5907
Commit
ec7c5907
authored
Mar 06, 2014
by
André Hentschel
Committed by
Alexandre Julliard
Mar 06, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ws2_32/tests: Test OOB data more sequential by sending bidirectional.
parent
6670bbf5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
6 deletions
+19
-6
sock.c
dlls/ws2_32/tests/sock.c
+19
-6
No files found.
dlls/ws2_32/tests/sock.c
View file @
ec7c5907
...
...
@@ -573,7 +573,7 @@ static VOID WINAPI oob_server ( server_params *par )
test_params
*
gen
=
par
->
general
;
server_memory
*
mem
;
u_long
atmark
=
0
;
int
pos
,
n_recvd
,
n_expected
=
gen
->
n_chunks
*
gen
->
chunk_size
,
tmp
,
int
pos
,
n_
sent
,
n_
recvd
,
n_expected
=
gen
->
n_chunks
*
gen
->
chunk_size
,
tmp
,
id
=
GetCurrentThreadId
();
trace
(
"oob_server (%x) starting
\n
"
,
id
);
...
...
@@ -598,17 +598,23 @@ static VOID WINAPI oob_server ( server_params *par )
ok
(
mem
->
sock
[
0
].
peer
.
sin_addr
.
s_addr
==
inet_addr
(
gen
->
inet_addr
),
"oob_server (%x): strange peer address
\n
"
,
id
);
/* check atmark state */
/* check
initial
atmark state */
ioctlsocket
(
mem
->
sock
[
0
].
s
,
SIOCATMARK
,
&
atmark
);
ok
(
atmark
==
1
,
"oob_server (%x): unexpectedly at the OOB mark: %i
\n
"
,
id
,
atmark
);
/* Receive normal data
and check atmark state
*/
/* Receive normal data */
n_recvd
=
do_synchronous_recv
(
mem
->
sock
[
0
].
s
,
mem
->
sock
[
0
].
buf
,
n_expected
,
par
->
buflen
);
ok
(
n_recvd
==
n_expected
,
"
simple
_server (%x): received less data than expected: %d of %d
\n
"
,
id
,
n_recvd
,
n_expected
);
"
oob
_server (%x): received less data than expected: %d of %d
\n
"
,
id
,
n_recvd
,
n_expected
);
pos
=
test_buffer
(
mem
->
sock
[
0
].
buf
,
gen
->
chunk_size
,
gen
->
n_chunks
);
ok
(
pos
==
-
1
,
"simple_server (%x): test pattern error: %d
\n
"
,
id
,
pos
);
ok
(
pos
==
-
1
,
"oob_server (%x): test pattern error: %d
\n
"
,
id
,
pos
);
/* Echo data back */
n_sent
=
do_synchronous_send
(
mem
->
sock
[
0
].
s
,
mem
->
sock
[
0
].
buf
,
n_expected
,
par
->
buflen
);
ok
(
n_sent
==
n_expected
,
"oob_server (%x): sent less data than expected: %d of %d
\n
"
,
id
,
n_sent
,
n_expected
);
/* check atmark state */
ioctlsocket
(
mem
->
sock
[
0
].
s
,
SIOCATMARK
,
&
atmark
);
ok
(
atmark
==
1
,
"oob_server (%x): unexpectedly at the OOB mark: %i
\n
"
,
id
,
atmark
);
...
...
@@ -824,7 +830,7 @@ static VOID WINAPI oob_client ( client_params *par )
{
test_params
*
gen
=
par
->
general
;
client_memory
*
mem
;
int
n_sent
,
n_expected
=
gen
->
n_chunks
*
gen
->
chunk_size
,
id
;
int
pos
,
n_sent
,
n_recvd
,
n_expected
=
gen
->
n_chunks
*
gen
->
chunk_size
,
id
;
id
=
GetCurrentThreadId
();
trace
(
"oob_client (%x): starting
\n
"
,
id
);
...
...
@@ -849,6 +855,13 @@ static VOID WINAPI oob_client ( client_params *par )
ok
(
n_sent
==
n_expected
,
"oob_client (%x): sent less data than expected: %d of %d
\n
"
,
id
,
n_sent
,
n_expected
);
/* Receive data echoed back & check it */
n_recvd
=
do_synchronous_recv
(
mem
->
s
,
mem
->
recv_buf
,
n_expected
,
par
->
buflen
);
ok
(
n_recvd
==
n_expected
,
"simple_client (%x): received less data than expected: %d of %d
\n
"
,
id
,
n_recvd
,
n_expected
);
pos
=
test_buffer
(
mem
->
recv_buf
,
gen
->
chunk_size
,
gen
->
n_chunks
);
ok
(
pos
==
-
1
,
"simple_client (%x): test pattern error: %d
\n
"
,
id
,
pos
);
/* send out-of-band data to server */
n_sent
=
do_oob_send
(
mem
->
s
,
mem
->
send_buf
,
n_expected
,
par
->
buflen
);
ok
(
n_sent
==
n_expected
,
...
...
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