teknoraver / rpms / systemd

Forked from rpms/systemd 2 months ago
Clone

Blame 0175-resolved-allow-DnsAnswer-objects-with-no-space-for-R.patch

Zbigniew Jędrzejewski-Szmek 05c903
From c3c65351593dde09a2d37b571e0737af94386fe6 Mon Sep 17 00:00:00 2001
Zbigniew Jędrzejewski-Szmek a48f80
From: Lennart Poettering <lennart@poettering.net>
Zbigniew Jędrzejewski-Szmek a48f80
Date: Mon, 18 May 2015 23:38:47 +0200
Zbigniew Jędrzejewski-Szmek a48f80
Subject: [PATCH] resolved: allow DnsAnswer objects with no space for RRs
Zbigniew Jędrzejewski-Szmek a48f80
Zbigniew Jędrzejewski-Szmek a48f80
They might be created as result of merged answer sets, hence accept
Zbigniew Jędrzejewski-Szmek a48f80
them.
Zbigniew Jędrzejewski-Szmek a48f80
Zbigniew Jędrzejewski-Szmek a48f80
http://lists.freedesktop.org/archives/systemd-devel/2015-April/030834.html
Zbigniew Jędrzejewski-Szmek a48f80
(cherry picked from commit 084cea6cee1471d81e078bea4e7ee5f50a5dc009)
Zbigniew Jędrzejewski-Szmek a48f80
---
Zbigniew Jędrzejewski-Szmek a48f80
 src/resolve/resolved-dns-answer.c | 2 --
Zbigniew Jędrzejewski-Szmek a48f80
 1 file changed, 2 deletions(-)
Zbigniew Jędrzejewski-Szmek a48f80
Zbigniew Jędrzejewski-Szmek a48f80
diff --git a/src/resolve/resolved-dns-answer.c b/src/resolve/resolved-dns-answer.c
Zbigniew Jędrzejewski-Szmek a48f80
index 7c4ab18b58..e08eb667cc 100644
Zbigniew Jędrzejewski-Szmek a48f80
--- a/src/resolve/resolved-dns-answer.c
Zbigniew Jędrzejewski-Szmek a48f80
+++ b/src/resolve/resolved-dns-answer.c
Zbigniew Jędrzejewski-Szmek a48f80
@@ -25,8 +25,6 @@
Zbigniew Jędrzejewski-Szmek a48f80
 DnsAnswer *dns_answer_new(unsigned n) {
Zbigniew Jędrzejewski-Szmek a48f80
         DnsAnswer *a;
Zbigniew Jędrzejewski-Szmek a48f80
 
Zbigniew Jędrzejewski-Szmek a48f80
-        assert(n > 0);
Zbigniew Jędrzejewski-Szmek a48f80
-
Zbigniew Jędrzejewski-Szmek a48f80
         a = malloc0(offsetof(DnsAnswer, rrs) + sizeof(DnsResourceRecord*) * n);
Zbigniew Jędrzejewski-Szmek a48f80
         if (!a)
Zbigniew Jędrzejewski-Szmek a48f80
                 return NULL;