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
01380b05
Commit
01380b05
authored
Dec 17, 2007
by
Kirill K. Smirnov
Committed by
Alexandre Julliard
Dec 18, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ws2_32: Fix flags conversion in getnameinfo() function.
parent
d701ee22
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
2 deletions
+24
-2
socket.c
dlls/ws2_32/socket.c
+24
-2
No files found.
dlls/ws2_32/socket.c
View file @
01380b05
...
...
@@ -327,6 +327,15 @@ static const int ws_aiflag_map[][2] =
*/
};
static
const
int
ws_niflag_map
[][
2
]
=
{
MAP_OPTION
(
NI_NOFQDN
),
MAP_OPTION
(
NI_NUMERICHOST
),
MAP_OPTION
(
NI_NAMEREQD
),
MAP_OPTION
(
NI_NUMERICSERV
),
MAP_OPTION
(
NI_DGRAM
),
};
static
const
int
ws_eai_map
[][
2
]
=
{
MAP_OPTION
(
EAI_AGAIN
),
...
...
@@ -3327,7 +3336,7 @@ void WINAPI WS_freeaddrinfo(struct WS_addrinfo *res)
}
}
/* helper functions for getaddrinfo() */
/* helper functions for getaddrinfo()
/getnameinfo()
*/
static
int
convert_aiflag_w2u
(
int
winflags
)
{
int
i
,
unixflags
=
0
;
...
...
@@ -3341,6 +3350,19 @@ static int convert_aiflag_w2u(int winflags) {
return
unixflags
;
}
static
int
convert_niflag_w2u
(
int
winflags
)
{
int
i
,
unixflags
=
0
;
for
(
i
=
0
;
i
<
sizeof
(
ws_niflag_map
)
/
sizeof
(
ws_niflag_map
[
0
]);
i
++
)
if
(
ws_niflag_map
[
i
][
0
]
&
winflags
)
{
unixflags
|=
ws_niflag_map
[
i
][
1
];
winflags
&=
~
ws_niflag_map
[
i
][
0
];
}
if
(
winflags
)
FIXME
(
"Unhandled windows NI_xxx flags %x
\n
"
,
winflags
);
return
unixflags
;
}
static
int
convert_aiflag_u2w
(
int
unixflags
)
{
int
i
,
winflags
=
0
;
...
...
@@ -3498,7 +3520,7 @@ int WINAPI WS_getnameinfo(const SOCKADDR *sa, WS_socklen_t salen, PCHAR host,
WSASetLastError
(
WSAEFAULT
);
return
WSA_NOT_ENOUGH_MEMORY
;
}
ret
=
getnameinfo
(
&
sa_u
.
addr
,
size
,
host
,
hostlen
,
serv
,
servlen
,
convert_
a
iflag_w2u
(
flags
));
ret
=
getnameinfo
(
&
sa_u
.
addr
,
size
,
host
,
hostlen
,
serv
,
servlen
,
convert_
n
iflag_w2u
(
flags
));
return
convert_eai_u2w
(
ret
);
#else
FIXME
(
"getnameinfo() failed, not found during buildtime.
\n
"
);
...
...
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