Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
Steve Lhomme
VLC
Commits
4268df2a
Commit
4268df2a
authored
Apr 25, 2016
by
Petri Hintukainen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
microdns: IPv6 support
parent
29c1c3fb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
modules/services_discovery/microdns.c
modules/services_discovery/microdns.c
+6
-4
No files found.
modules/services_discovery/microdns.c
View file @
4268df2a
...
...
@@ -301,6 +301,7 @@ parse_entries( const struct rr_entry *p_entries, bool b_renderer,
/* There is one ip for several srvs, fetch them */
const
char
*
psz_ip
=
NULL
;
char
psz_ip6
[
INET6_ADDRSTRLEN
+
2
];
i_nb_srv
=
0
;
for
(
const
struct
rr_entry
*
p_entry
=
p_entries
;
p_entry
!=
NULL
;
p_entry
=
p_entry
->
next
)
...
...
@@ -329,10 +330,11 @@ parse_entries( const struct rr_entry *p_entries, bool b_renderer,
}
else
if
(
p_entry
->
type
==
RR_A
&&
psz_ip
==
NULL
)
psz_ip
=
p_entry
->
data
.
A
.
addr_str
;
/* TODO support ipv6
else if( p_entry->type == RR_AAAA )
psz_ip = p_entry->data.AAAA.addr_str;
*/
else
if
(
p_entry
->
type
==
RR_AAAA
&&
psz_ip
==
NULL
)
{
if
(
snprintf
(
psz_ip6
,
sizeof
(
psz_ip6
),
"[%s]"
,
p_entry
->
data
.
AAAA
.
addr_str
)
>
0
)
psz_ip
=
psz_ip6
;
}
}
if
(
psz_ip
==
NULL
||
i_nb_srv
==
0
)
{
...
...
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