2015-04-21 11:53:13 +02:00
|
|
|
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
|
|
|
|
---
|
2017-09-12 15:53:00 +02:00
|
|
|
ping.c | 11 -----------
|
|
|
|
1 file changed, 11 deletions(-)
|
2015-04-21 11:53:13 +02:00
|
|
|
|
|
|
|
diff --git a/ping.c b/ping.c
|
2017-09-12 15:53:00 +02:00
|
|
|
index 75420b8..0668a18 100644
|
2015-04-21 11:53:13 +02:00
|
|
|
--- a/ping.c
|
|
|
|
+++ b/ping.c
|
2017-09-12 15:53:00 +02:00
|
|
|
@@ -968,17 +968,6 @@ int ping4_receive_error_msg(socket_st *sock)
|
2015-04-21 11:53:13 +02:00
|
|
|
|
|
|
|
acknowledge(ntohs(icmph.un.echo.sequence));
|
|
|
|
|
2015-12-03 02:18:20 +01:00
|
|
|
- if (sock->socktype == SOCK_RAW && !sock->working_recverr) {
|
2015-04-21 11:53:13 +02:00
|
|
|
- struct icmp_filter filt;
|
2015-12-03 02:18:20 +01:00
|
|
|
- sock->working_recverr = 1;
|
2015-04-21 11:53:13 +02:00
|
|
|
- /* OK, it works. Add stronger filter. */
|
2015-12-03 02:18:20 +01:00
|
|
|
- filt.data = ~((1<<ICMP_SOURCE_QUENCH)|
|
|
|
|
- (1<<ICMP_REDIRECT)|
|
|
|
|
- (1<<ICMP_ECHOREPLY));
|
|
|
|
- if (setsockopt(sock->fd, SOL_RAW, ICMP_FILTER, (char*)&filt, sizeof(filt)) == -1)
|
2015-04-21 11:53:13 +02:00
|
|
|
- perror("\rWARNING: setsockopt(ICMP_FILTER)");
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
net_errors++;
|
|
|
|
nerrors++;
|
|
|
|
if (options & F_QUIET)
|
|
|
|
--
|
2017-09-12 15:53:00 +02:00
|
|
|
2.14.1
|
2015-04-21 11:53:13 +02:00
|
|
|
|