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
43241934
Commit
43241934
authored
May 07, 2014
by
Bruno Jesus
Committed by
Alexandre Julliard
May 08, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ws2_32: Avoid using WS_ prefix on unix sockaddr struct.
The address was already converted to unix in these situations, so it's wrong to check against windows #defines.
parent
3bca22a6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
socket.c
dlls/ws2_32/socket.c
+4
-4
No files found.
dlls/ws2_32/socket.c
View file @
43241934
...
...
@@ -2559,7 +2559,7 @@ static BOOL interface_bind( SOCKET s, int fd, struct sockaddr *addr )
DWORD
adap_size
;
int
enable
=
1
;
if
(
bind_addr
==
htonl
(
WS_INADDR_ANY
)
||
bind_addr
==
htonl
(
WS_
INADDR_LOOPBACK
))
if
(
bind_addr
==
htonl
(
INADDR_ANY
)
||
bind_addr
==
htonl
(
INADDR_LOOPBACK
))
return
FALSE
;
/* Not binding to a network adapter, special interface binding unnecessary. */
if
(
getsockopt
(
fd
,
SOL_SOCKET
,
SO_TYPE
,
&
sock_type
,
&
optlen
)
==
-
1
||
sock_type
!=
SOCK_DGRAM
)
return
FALSE
;
/* Special interface binding is only necessary for UDP datagrams. */
...
...
@@ -2664,10 +2664,10 @@ int WINAPI WS_bind(SOCKET s, const struct WS_sockaddr* name, int namelen)
* INADDR_ANY instead*/
WARN
(
"Trying to bind to magic IP address, using "
"INADDR_ANY instead.
\n
"
);
in4
->
sin_addr
.
s_addr
=
htonl
(
WS_
INADDR_ANY
);
in4
->
sin_addr
.
s_addr
=
htonl
(
INADDR_ANY
);
}
else
if
(
interface_bind
(
s
,
fd
,
&
uaddr
.
addr
))
in4
->
sin_addr
.
s_addr
=
htonl
(
WS_
INADDR_ANY
);
in4
->
sin_addr
.
s_addr
=
htonl
(
INADDR_ANY
);
}
if
(
bind
(
fd
,
&
uaddr
.
addr
,
uaddrlen
)
<
0
)
{
...
...
@@ -2725,7 +2725,7 @@ static int do_connect(int fd, const struct WS_sockaddr* name, int namelen)
* assuming we really want to connect to localhost */
TRACE
(
"Trying to connect to magic IP address, using "
"INADDR_LOOPBACK instead.
\n
"
);
in4
->
sin_addr
.
s_addr
=
htonl
(
WS_
INADDR_LOOPBACK
);
in4
->
sin_addr
.
s_addr
=
htonl
(
INADDR_LOOPBACK
);
}
}
...
...
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