diff options
author | Adam Duskett <Aduskett@gmail.com> | 2017-07-31 10:22:09 -0400 |
---|---|---|
committer | Thomas Petazzoni <thomas.petazzoni@free-electrons.com> | 2017-08-02 21:49:00 +0200 |
commit | 333dccb14472d67fc42f2fa01fe21808bd53f1ec (patch) | |
tree | d2629289095c46f7a894f31d315e8f6bf7b81bc4 /package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch | |
parent | 3edad4614b6f502b39e893c2e0487829215e3642 (diff) | |
download | buildroot-333dccb14472d67fc42f2fa01fe21808bd53f1ec.tar.gz buildroot-333dccb14472d67fc42f2fa01fe21808bd53f1ec.zip |
systemd: bump version to 234
Other changes:
- Removed the following patches due to being merged upstream:
- resolved-bugfix-of-null-pointer-p-question-dereferencing.patch
- resolved-simplify-alloc-size-calculation.patch
- resolved-do-not-allocate-packets-with-minimum-size.patch
- Updated the following patches to work with 234:
- fix-getty-unit.patch
- build-check-for-ln-relative.patch
- fix-am-path-libgcrypt-no-found.patch
- Updated ordering of remaining patches.
- Reformatted remaining patches as git style patches.
- Updated Upstream-Status comment in "build-check-for-ln-relative.patch" to
"Denied [No desire to support building on old distributions]"
Signed-off-by: Adam Duskett <aduskett@gmail.com>
Tested-by: Marcus Hoffmann <m.hoffmann@caretelsol.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch')
-rw-r--r-- | package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch b/package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch deleted file mode 100644 index 750911383c..0000000000 --- a/package/systemd/0003-resolved-do-not-allocate-packets-with-minimum-size.patch +++ /dev/null @@ -1,48 +0,0 @@ -From 88795538726a5bbfd9efc13d441cb05e1d7fc139 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl> -Date: Tue, 27 Jun 2017 14:20:00 -0400 -Subject: [PATCH] resolved: do not allocate packets with minimum size - -dns_packet_new() is sometimes called with mtu == 0, and in that case we should -allocate more than the absolute minimum (which is the dns packet header size), -otherwise we have to resize immediately again after appending the first data to -the packet. - -This partially reverts the previous commit. - -[Upstream commit: https://github.com/systemd/systemd/commit/88795538726a5bbfd9efc13d441cb05e1d7fc139] -Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> ---- - src/resolve/resolved-dns-packet.c | 12 +++++++++++- - 1 file changed, 11 insertions(+), 1 deletion(-) - -diff --git a/src/resolve/resolved-dns-packet.c b/src/resolve/resolved-dns-packet.c -index 821b66e266..d1f0f760a4 100644 ---- a/src/resolve/resolved-dns-packet.c -+++ b/src/resolve/resolved-dns-packet.c -@@ -28,6 +28,9 @@ - - #define EDNS0_OPT_DO (1<<15) - -+#define DNS_PACKET_SIZE_START 512 -+assert_cc(DNS_PACKET_SIZE_START > UDP_PACKET_HEADER_SIZE) -+ - typedef struct DnsPacketRewinder { - DnsPacket *packet; - size_t saved_rindex; -@@ -47,7 +50,14 @@ int dns_packet_new(DnsPacket **ret, DnsProtocol protocol, size_t mtu) { - - assert(ret); - -- a = MAX(mtu, DNS_PACKET_HEADER_SIZE); -+ /* When dns_packet_new() is called with mtu == 0, allocate more than the -+ * absolute minimum (which is the dns packet header size), to avoid -+ * resizing immediately again after appending the first data to the packet. -+ */ -+ if (mtu < UDP_PACKET_HEADER_SIZE) -+ a = DNS_PACKET_SIZE_START; -+ else -+ a = MAX(mtu, DNS_PACKET_HEADER_SIZE); - - /* round up to next page size */ - a = PAGE_ALIGN(ALIGN(sizeof(DnsPacket)) + a) - ALIGN(sizeof(DnsPacket)); |