forked from pool/iputils
Accepting request 298213 from home:tiwai:branches:network:utilities
- Fix a bogus kernel version check (boo#927831): iputils-remove-bogus-check-required-for-2.4.9-kernels.patch OBS-URL: https://build.opensuse.org/request/show/298213 OBS-URL: https://build.opensuse.org/package/show/network:utilities/iputils?expand=0&rev=38
This commit is contained in:
parent
2b136b3d11
commit
56d494d8f8
56
iputils-remove-bogus-check-required-for-2.4.9-kernels.patch
Normal file
56
iputils-remove-bogus-check-required-for-2.4.9-kernels.patch
Normal file
@ -0,0 +1,56 @@
|
||||
From 5bb0f0a8b0ed6f111a329c0d6911dfa516ab1d42 Mon Sep 17 00:00:00 2001
|
||||
From: Noah Meyerhans <noahm@debian.org>
|
||||
Date: Fri, 18 Apr 2014 15:47:29 +0200
|
||||
Subject: [PATCH] remove bogus check required for < 2.4.9 kernels
|
||||
|
||||
Debian bug: #709052
|
||||
---
|
||||
ping.c | 25 +------------------------
|
||||
1 file changed, 1 insertion(+), 24 deletions(-)
|
||||
|
||||
diff --git a/ping.c b/ping.c
|
||||
index b9d649531621..f9f4a28f5dc1 100644
|
||||
--- a/ping.c
|
||||
+++ b/ping.c
|
||||
@@ -654,17 +654,6 @@ int receive_error_msg()
|
||||
|
||||
acknowledge(ntohs(icmph.un.echo.sequence));
|
||||
|
||||
- if (!working_recverr) {
|
||||
- struct icmp_filter filt;
|
||||
- working_recverr = 1;
|
||||
- /* OK, it works. Add stronger filter. */
|
||||
- filt.data = ~((1<<ICMP_SOURCE_QUENCH)|
|
||||
- (1<<ICMP_REDIRECT)|
|
||||
- (1<<ICMP_ECHOREPLY));
|
||||
- if (setsockopt(icmp_sock, SOL_RAW, ICMP_FILTER, (char*)&filt, sizeof(filt)) == -1)
|
||||
- perror("\rWARNING: setsockopt(ICMP_FILTER)");
|
||||
- }
|
||||
-
|
||||
net_errors++;
|
||||
nerrors++;
|
||||
if (options & F_QUIET)
|
||||
@@ -820,19 +809,7 @@ parse_reply(struct msghdr *msg, int cc, void *addr, struct timeval *tv)
|
||||
icp->type != ICMP_SOURCE_QUENCH);
|
||||
if (error_pkt) {
|
||||
acknowledge(ntohs(icp1->un.echo.sequence));
|
||||
- if (working_recverr) {
|
||||
- return 0;
|
||||
- } else {
|
||||
- static int once;
|
||||
- /* Sigh, IP_RECVERR for raw socket
|
||||
- * was broken until 2.4.9. So, we ignore
|
||||
- * the first error and warn on the second.
|
||||
- */
|
||||
- if (once++ == 1)
|
||||
- fprintf(stderr, "\rWARNING: kernel is not very fresh, upgrade is recommended.\n");
|
||||
- if (once == 1)
|
||||
- return 0;
|
||||
- }
|
||||
+ return 0;
|
||||
}
|
||||
nerrors+=error_pkt;
|
||||
if (options&F_QUIET)
|
||||
--
|
||||
2.3.5
|
||||
|
@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Apr 20 17:07:42 CEST 2015 - tiwai@suse.de
|
||||
|
||||
- Fix a bogus kernel version check (boo#927831):
|
||||
iputils-remove-bogus-check-required-for-2.4.9-kernels.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Jan 28 08:13:46 CET 2014 - hare@suse.de
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package iputils
|
||||
#
|
||||
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -36,6 +36,8 @@ Patch2: iputils-traceroute6-stdint.diff
|
||||
Patch3: iputils-ifenslave.diff
|
||||
Patch8: iputils-s20101006-sec-ping-unblock.diff
|
||||
Patch9: iputils-s20101006-ping-interrupt.diff
|
||||
# PATCH-FIX-UPSTREAM iputils-remove-bogus-check-required-for-2.4.9-kernels.patch tiwai@suse.de - boo#927831
|
||||
Patch10: iputils-remove-bogus-check-required-for-2.4.9-kernels.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
PreReq: permissions
|
||||
|
||||
@ -50,6 +52,7 @@ cp -a %SOURCE1 .
|
||||
%patch3
|
||||
%patch8 -p1
|
||||
%patch9 -p1
|
||||
%patch10 -p1
|
||||
|
||||
%build
|
||||
make %{?_smp_mflags} KERNEL_INCLUDE=$PWD \
|
||||
|
Loading…
Reference in New Issue
Block a user