summaryrefslogtreecommitdiff
path: root/src/resolve/resolved-dns-packet.h
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2017-06-18 16:07:57 -0400
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2017-06-27 13:19:52 -0400
commitdb848813bae4d28c524b3b6a7dad135e426659ce (patch)
tree61eb8437166b70d9bcdd95a56ec2a7f1d98c4cc9 /src/resolve/resolved-dns-packet.h
parent751ca3f1de316ca79b60001334dbdf54077e1d01 (diff)
downloadsystemd-db848813bae4d28c524b3b6a7dad135e426659ce.tar.gz
resolved: simplify alloc size calculation
The allocation size was calculated in a complicated way, and for values close to the page size we would actually allocate less than requested. Reported by Chris Coulson <chris.coulson@canonical.com>. CVE-2017-9445
Diffstat (limited to 'src/resolve/resolved-dns-packet.h')
-rw-r--r--src/resolve/resolved-dns-packet.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/resolve/resolved-dns-packet.h b/src/resolve/resolved-dns-packet.h
index 2c92392e4d..3abcaf8cf3 100644
--- a/src/resolve/resolved-dns-packet.h
+++ b/src/resolve/resolved-dns-packet.h
@@ -66,8 +66,6 @@ struct DnsPacketHeader {
/* With EDNS0 we can use larger packets, default to 4096, which is what is commonly used */
#define DNS_PACKET_UNICAST_SIZE_LARGE_MAX 4096
-#define DNS_PACKET_SIZE_START 512
-
struct DnsPacket {
int n_ref;
DnsProtocol protocol;