Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
0707e3ff
Commit
0707e3ff
authored
Mar 28, 2010
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
getaddrinfo() may list IPv6 even if not supported
This fixes the RTP input failing completely.
parent
c175d930
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
14 deletions
+2
-14
src/network/udp.c
src/network/udp.c
+2
-14
No files found.
src/network/udp.c
View file @
0707e3ff
...
@@ -180,25 +180,13 @@ static int net_ListenSingle (vlc_object_t *obj, const char *host, int port,
...
@@ -180,25 +180,13 @@ static int net_ListenSingle (vlc_object_t *obj, const char *host, int port,
int
on
=
(
family
==
AF_INET6
);
int
on
=
(
family
==
AF_INET6
);
setsockopt
(
fd
,
SOL_IPV6
,
IPV6_V6ONLY
,
&
on
,
sizeof
(
on
));
setsockopt
(
fd
,
SOL_IPV6
,
IPV6_V6ONLY
,
&
on
,
sizeof
(
on
));
}
}
else
if
(
ptr
->
ai_family
==
AF_INET
&&
family
==
AF_UNSPEC
)
if
(
ptr
->
ai_family
==
AF_INET
)
{
#endif
for
(
const
struct
addrinfo
*
p
=
ptr
;
p
!=
NULL
;
p
=
p
->
ai_next
)
if
(
p
->
ai_family
==
AF_INET6
)
{
net_Close
(
fd
);
fd
=
-
1
;
break
;
}
if
(
fd
==
-
1
)
continue
;
}
#else
if
(
family
==
AF_UNSPEC
&&
ptr
->
ai_next
!=
NULL
)
if
(
family
==
AF_UNSPEC
&&
ptr
->
ai_next
!=
NULL
)
{
{
msg_Warn
(
obj
,
"ambiguous network protocol specification"
);
msg_Warn
(
obj
,
"ambiguous network protocol specification"
);
msg_Warn
(
obj
,
"please select IP version explicitly"
);
msg_Warn
(
obj
,
"please select IP version explicitly"
);
}
}
#endif
fd
=
net_SetupDgramSocket
(
obj
,
fd
,
ptr
);
fd
=
net_SetupDgramSocket
(
obj
,
fd
,
ptr
);
if
(
fd
==
-
1
)
if
(
fd
==
-
1
)
...
...
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