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
41cdc667
Commit
41cdc667
authored
Jul 11, 2022
by
Zebediah Figura
Committed by
Alexandre Julliard
Jul 21, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
server: Report the socket error in sock_poll_event() on POLLERR or POLLHUP.
Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=52815
parent
a2f2b773
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
afd.c
dlls/ws2_32/tests/afd.c
+2
-1
sock.c
server/sock.c
+3
-3
No files found.
dlls/ws2_32/tests/afd.c
View file @
41cdc667
...
...
@@ -162,7 +162,8 @@ static void check_poll_(int line, SOCKET s, HANDLE event, int mask, int expect,
ok_
(
__FILE__
,
line
)(
out_params
.
count
==
1
,
"got count %u
\n
"
,
out_params
.
count
);
ok_
(
__FILE__
,
line
)(
out_params
.
sockets
[
0
].
socket
==
s
,
"got socket %#Ix
\n
"
,
out_params
.
sockets
[
0
].
socket
);
todo_wine_if
(
todo
)
ok_
(
__FILE__
,
line
)(
out_params
.
sockets
[
0
].
flags
==
expect
,
"got flags %#x
\n
"
,
out_params
.
sockets
[
0
].
flags
);
ok_
(
__FILE__
,
line
)(
!
out_params
.
sockets
[
0
].
status
,
"got status %#x
\n
"
,
out_params
.
sockets
[
0
].
status
);
todo_wine_if
(
expect
&
AFD_POLL_RESET
)
ok_
(
__FILE__
,
line
)(
!
out_params
.
sockets
[
0
].
status
,
"got status %#x
\n
"
,
out_params
.
sockets
[
0
].
status
);
}
static
void
test_poll
(
void
)
...
...
server/sock.c
View file @
41cdc667
...
...
@@ -1145,6 +1145,9 @@ static void sock_poll_event( struct fd *fd, int event )
if
(
debug_level
)
fprintf
(
stderr
,
"socket %p select event: %x
\n
"
,
sock
,
event
);
if
(
event
&
(
POLLERR
|
POLLHUP
))
error
=
sock_error
(
sock
);
switch
(
sock
->
state
)
{
case
SOCK_UNCONNECTED
:
...
...
@@ -1153,7 +1156,6 @@ static void sock_poll_event( struct fd *fd, int event )
case
SOCK_CONNECTING
:
if
(
event
&
(
POLLERR
|
POLLHUP
))
{
error
=
sock_error
(
sock
);
sock
->
state
=
SOCK_UNCONNECTED
;
event
&=
~
POLLOUT
;
}
...
...
@@ -1166,8 +1168,6 @@ static void sock_poll_event( struct fd *fd, int event )
break
;
case
SOCK_LISTENING
:
if
(
event
&
(
POLLERR
|
POLLHUP
))
error
=
sock_error
(
sock
);
break
;
case
SOCK_CONNECTED
:
...
...
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