[Spice-devel] [PATCH spice-gtk 2/2] session: Keep brackets around ipv6 hostname
Marc-André Lureau
mlureau at redhat.com
Tue Jun 21 13:20:34 UTC 2016
ack
----- Original Message -----
> According to rfc2732:
> "To use a literal IPv6 address in a URL, the literal address should be
> enclosed in "[" and "]" characters."
>
> Resolves: rhbz#1331777
> ---
> src/spice-session.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/spice-session.c b/src/spice-session.c
> index 888d9fb..db283d4 100644
> --- a/src/spice-session.c
> +++ b/src/spice-session.c
> @@ -476,7 +476,7 @@ static int spice_parse_uri(SpiceSession *session, const
> char *original_uri)
> }
> tmp[0] = '\0';
> tmp++;
> - host = g_strdup(authority + 1);
> + host = g_strdup_printf("[%s]", authority + 1);
> if (tmp[0] == ':')
> port = g_strdup(tmp + 1);
> } else {
> --
> 2.9.0
>
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/spice-devel
>
More information about the Spice-devel
mailing list