From 74f031719a01b0a60d91ca0c265541be2e6afeafbeb125cb878083385d4ee335 Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Fri, 23 Aug 2019 13:03:57 +0000 Subject: [PATCH] Accepting request 724875 from home:mwilck:branches:network:utilities - Fix arping -D problem (bsc#1146440) * added arping-revert-partially-fix-sent-vs-received-package.patch (upstream commit 18f14be) OBS-URL: https://build.opensuse.org/request/show/724875 OBS-URL: https://build.opensuse.org/package/show/network:utilities/iputils?expand=0&rev=76 --- ...rtially-fix-sent-vs-received-package.patch | 37 +++++++++++++++++++ iputils.changes | 7 ++++ iputils.spec | 2 + 3 files changed, 46 insertions(+) create mode 100644 arping-revert-partially-fix-sent-vs-received-package.patch diff --git a/arping-revert-partially-fix-sent-vs-received-package.patch b/arping-revert-partially-fix-sent-vs-received-package.patch new file mode 100644 index 0000000..7bb1ec5 --- /dev/null +++ b/arping-revert-partially-fix-sent-vs-received-package.patch @@ -0,0 +1,37 @@ +From 18f14be80466ddc8fb17a400be82764a779c8dcd Mon Sep 17 00:00:00 2001 +From: Sami Kerola +Date: Wed, 31 Jul 2019 21:28:12 +0100 +Subject: [PATCH] arping: revert partially - fix sent vs received packages + return value + +Commit 84ca65ca980315c73f929fed8b6f16bbd698c3a0 caused regression. The +arping -D needs return value evaluation that was the earlier default, in +other cases the new return value should be correct. + +Addresses: https://github.com/iputils/iputils/issues/209 +See-also: https://github.com/void-linux/void-packages/issues/13304 +Signed-off-by: Sami Kerola +--- + arping.c | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/arping.c b/arping.c +index 77c9c56..2c87c15 100644 +--- a/arping.c ++++ b/arping.c +@@ -792,7 +792,11 @@ static int event_loop(struct run_state *ctl) + close(tfd); + freeifaddrs(ctl->ifa0); + rc |= finish(ctl); +- rc |= (ctl->sent != ctl->received); ++ if (ctl->dad && ctl->quit_on_reply) ++ /* Duplicate address detection mode return value */ ++ rc |= !(ctl->brd_sent != ctl->received); ++ else ++ rc |= (ctl->sent != ctl->received); + return rc; + } + +-- +2.22.0 + diff --git a/iputils.changes b/iputils.changes index d7276a2..eb18e54 100644 --- a/iputils.changes +++ b/iputils.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Tue Aug 20 17:31:48 UTC 2019 - Martin Wilck + +- Fix arping -D problem (bsc#1146440) + * added arping-revert-partially-fix-sent-vs-received-package.patch + (upstream commit 18f14be) + ------------------------------------------------------------------- Fri Jul 26 06:19:44 UTC 2019 - Petr Vorel diff --git a/iputils.spec b/iputils.spec index e51fdfe..4794a9e 100644 --- a/iputils.spec +++ b/iputils.spec @@ -27,6 +27,7 @@ Source0: https://github.com/iputils/iputils/archive/%{version}.tar.gz Source1: rarpd.service Patch1: iputils-sec-ping-unblock.diff Patch2: iputils-ping-interrupt.diff +Patch3: arping-revert-partially-fix-sent-vs-received-package.patch BuildRequires: docbook5-xsl-stylesheets BuildRequires: docbook_5 BuildRequires: iso_ent @@ -67,6 +68,7 @@ out their IP addresses. %setup -q %patch1 -p1 %patch2 -p1 +%patch3 -p1 %build # Export CFLAGS so we can also benefit from the ones the Makefile sets for us