Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
3c88562c
Commit
3c88562c
authored
Aug 24, 2007
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add some missing items to the getaddrinfo flags whitelist list, and comment
parent
d0f7b990
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
2 deletions
+17
-2
src/network/getaddrinfo.c
src/network/getaddrinfo.c
+17
-2
No files found.
src/network/getaddrinfo.c
View file @
3c88562c
...
...
@@ -583,13 +583,28 @@ int vlc_getaddrinfo( vlc_object_t *p_this, const char *node,
memset
(
&
hints
,
0
,
sizeof
(
hints
));
if
(
p_hints
!=
NULL
)
{
const
int
safe_flags
=
AI_NUMERICHOST
|
AI_NUMERICSERV
|
AI_PASSIVE
|
AI_CANONNAME
|
AI_ALL
|
AI_ADDRCONFIG
|
AI_V4MAPPED
|
0
;
hints
.
ai_family
=
p_hints
->
ai_family
;
hints
.
ai_socktype
=
p_hints
->
ai_socktype
;
hints
.
ai_protocol
=
p_hints
->
ai_protocol
;
hints
.
ai_flags
=
p_hints
->
ai_flags
&
(
AI_NUMERICHOST
|
AI_PASSIVE
|
AI_CANONNAME
);
/* Unfortunately, some flags chang the layout of struct addrinfo, so
* they cannot be copied blindly from p_hints to &hints. Therefore, we
* only copy flags that we know for sure are "safe".
*/
hints
.
ai_flags
=
p_hints
->
ai_flags
&
safe_flags
;
}
#ifdef AI_NUMERICSERV
/*
w
e only ever use port *numbers* */
/*
W
e only ever use port *numbers* */
hints
.
ai_flags
|=
AI_NUMERICSERV
;
#endif
...
...
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