aboutsummaryrefslogtreecommitdiff
path: root/networking/ping.c
diff options
context:
space:
mode:
Diffstat (limited to 'networking/ping.c')
-rw-r--r--networking/ping.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/networking/ping.c b/networking/ping.c
index 774f8f3e0..d1d59d545 100644
--- a/networking/ping.c
+++ b/networking/ping.c
@@ -135,6 +135,14 @@
# define ICMP_ADDRESSREPLY 18 /* Address Mask Reply */
#endif
+/* Some operating systems, like GNU/Hurd, don't define SOL_RAW, but do have
+ * IPPROTO_RAW. Since the IPPROTO definitions are also valid to use for
+ * setsockopt (and take the same value as their corresponding SOL definitions,
+ * if they exist), we can just fall back on IPPROTO_RAW. */
+#ifndef SOL_RAW
+# define SOL_RAW IPPROTO_RAW
+#endif
+
#if ENABLE_PING6
# include <netinet/icmp6.h>
/* I see RENUMBERED constants in bits/in.h - !!?