Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
10d51ce8
Commit
10d51ce8
authored
Mar 29, 2015
by
Bruno Jesus
Committed by
Alexandre Julliard
Mar 30, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ws2_32: Check for OOB data in select() calls when not OOB_INLINED.
parent
10f72652
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
socket.c
dlls/ws2_32/socket.c
+8
-0
sock.c
dlls/ws2_32/tests/sock.c
+0
-2
No files found.
dlls/ws2_32/socket.c
View file @
10d51ce8
...
...
@@ -4516,7 +4516,15 @@ static struct pollfd *fd_sets_to_poll( const WS_fd_set *readfds, const WS_fd_set
fds
[
j
].
revents
=
0
;
if
(
is_fd_bound
(
fds
[
j
].
fd
,
NULL
,
NULL
)
==
1
)
{
int
oob_inlined
=
0
;
socklen_t
olen
=
sizeof
(
oob_inlined
);
fds
[
j
].
events
=
POLLHUP
;
/* Check if we need to test for urgent data or not */
getsockopt
(
fds
[
j
].
fd
,
SOL_SOCKET
,
SO_OOBINLINE
,
(
char
*
)
&
oob_inlined
,
&
olen
);
if
(
!
oob_inlined
)
fds
[
j
].
events
|=
POLLPRI
;
}
else
{
...
...
dlls/ws2_32/tests/sock.c
View file @
10d51ce8
...
...
@@ -3626,9 +3626,7 @@ static void test_select(void)
FD_SET
(
fdRead
,
&
readfds
);
FD_SET
(
fdRead
,
&
exceptfds
);
ret
=
select
(
0
,
&
readfds
,
&
writefds
,
&
exceptfds
,
&
select_timeout
);
todo_wine
ok
(
ret
==
1
,
"expected 1, got %d
\n
"
,
ret
);
todo_wine
ok
(
FD_ISSET
(
fdRead
,
&
exceptfds
),
"fdRead socket is not in the set
\n
"
);
tmp_buf
[
0
]
=
0xAF
;
ret
=
recv
(
fdRead
,
tmp_buf
,
sizeof
(
tmp_buf
),
MSG_OOB
);
...
...
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