From 85818582574bcd1c3707c2a4609c9e283e47493f Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Thu, 31 Jul 2014 19:54:24 +0200 Subject: [PATCH] resolved: fix deserialization of UTF8 host names --- src/resolve/resolved-dns-packet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/resolve/resolved-dns-packet.c b/src/resolve/resolved-dns-packet.c index 3eda803144d..7793a014df9 100644 --- a/src/resolve/resolved-dns-packet.c +++ b/src/resolve/resolved-dns-packet.c @@ -840,7 +840,7 @@ int dns_packet_read_name(DnsPacket *p, char **_ret, size_t *start) { else first = false; - memcpy(ret + n, t, c); + memcpy(ret + n, t, r); n += r; continue; } else if ((c & 0xc0) == 0xc0) {