[arch-commits] Commit in opendht/trunk (2 files)

Baptiste Jonglez zorun at archlinux.org
Fri Jul 14 10:46:49 UTC 2017


    Date: Friday, July 14, 2017 @ 10:46:49
  Author: zorun
Revision: 245074

upgpkg: opendht 1:1.3.4-1

Added:
  opendht/trunk/0001-network-prevent-sending-packets-larger-than-1280-byt.patch
Modified:
  opendht/trunk/PKGBUILD

-----------------------------------------------------------------+
 0001-network-prevent-sending-packets-larger-than-1280-byt.patch |   25 ++++++++++
 PKGBUILD                                                        |   13 ++++-
 2 files changed, 35 insertions(+), 3 deletions(-)

Added: 0001-network-prevent-sending-packets-larger-than-1280-byt.patch
===================================================================
--- 0001-network-prevent-sending-packets-larger-than-1280-byt.patch	                        (rev 0)
+++ 0001-network-prevent-sending-packets-larger-than-1280-byt.patch	2017-07-14 10:46:49 UTC (rev 245074)
@@ -0,0 +1,25 @@
+From 8a123f9f68e93452dc2c044f8a2ffa07a6038364 Mon Sep 17 00:00:00 2001
+From: Adrien Beraud <adrien.beraud at savoirfairelinux.com>
+Date: Sun, 9 Jul 2017 07:51:05 -0400
+Subject: [PATCH 1/2] network: prevent sending packets larger than 1280 bytes
+
+---
+ include/opendht/network_engine.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/opendht/network_engine.h b/include/opendht/network_engine.h
+index 53f9044..a037cde 100644
+--- a/include/opendht/network_engine.h
++++ b/include/opendht/network_engine.h
+@@ -464,7 +464,7 @@ private:
+     static constexpr unsigned BLACKLISTED_MAX {10};
+ 
+     static constexpr size_t MTU {1280};
+-    static constexpr size_t MAX_PACKET_VALUE_SIZE {8 * 1024};
++    static constexpr size_t MAX_PACKET_VALUE_SIZE {600};
+ 
+     static const std::string my_v;
+     static std::mt19937 rd_device;
+-- 
+2.13.2
+

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2017-07-14 10:45:34 UTC (rev 245073)
+++ PKGBUILD	2017-07-14 10:46:49 UTC (rev 245074)
@@ -1,6 +1,6 @@
 # Maintainer: Baptiste Jonglez <baptiste--aur at jonglez dot org>
 pkgname=opendht
-pkgver=1.3.3
+pkgver=1.3.4
 pkgrel=1
 epoch=1
 pkgdesc="A C++11 implementation of the Kademlia DHT (Distributed Hash Table)"
@@ -10,9 +10,16 @@
 optdepends=('python: to use the Python bindings')
 url="https://github.com/savoirfairelinux/opendht"
 license=('GPL3')
-source=("https://github.com/savoirfairelinux/opendht/archive/${pkgver}/${pkgname}-${pkgver}.tar.gz")
-sha256sums=('0ba0d3eedd38e1e6d1d62ae8a4181a5beb4b18b508145e40f9759fc687bc881d')
+source=("https://github.com/savoirfairelinux/opendht/archive/${pkgver}/${pkgname}-${pkgver}.tar.gz"
+        "0001-network-prevent-sending-packets-larger-than-1280-byt.patch")
+sha256sums=('348e956b55bc377310de214846b96aa7557239bc8c2dffc70a97295de081b354'
+            'fb586a26828da442d041e4457fc0da1a2f6c21525e0630a7f7c912625b8b6d8d')
 
+prepare() {
+  cd "${srcdir}/${pkgname}-${pkgver}"
+  patch -p1 < "${srcdir}/0001-network-prevent-sending-packets-larger-than-1280-byt.patch"
+}
+
 build() {
   cd "${srcdir}/${pkgname}-${pkgver}"
 



More information about the arch-commits mailing list