aboutsummaryrefslogtreecommitdiff
path: root/net/fping/files
diff options
context:
space:
mode:
authorEugene Grosbein <eugen@FreeBSD.org>2019-06-19 20:07:44 +0000
committerEugene Grosbein <eugen@FreeBSD.org>2019-06-19 20:07:44 +0000
commita3ab4375e37cc38b01c6f0dc9d4d1818dfe7ac88 (patch)
treef9d3126f4176822cdc75c8747bc514520681b27f /net/fping/files
parenta63952412f2ca4926141773a79f2cfc159118564 (diff)
downloadports-a3ab4375e37cc38b01c6f0dc9d4d1818dfe7ac88.tar.gz
ports-a3ab4375e37cc38b01c6f0dc9d4d1818dfe7ac88.zip
net/fping: fix WITHOUT_IPV6 mode
If one builds and uses net/fping version 4.2 with option IPV6 disabled, the command fping -4 always fails with wrong error message: fping: can't specify both -4 and -6 This makes it impossible using fping probes with SmokePing as it runs fping with -4 option. This change fixes this. Also, do not install symlinks for fping6 and manual in this case. PORTREVISION not bumped as default build is not affected. PR: 238327 Approved by: jharris@widomaker.com (maintainter timeout, 2 weeks)
Notes
Notes: svn path=/head/; revision=504585
Diffstat (limited to 'net/fping/files')
-rw-r--r--net/fping/files/patch-src_fping.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/net/fping/files/patch-src_fping.c b/net/fping/files/patch-src_fping.c
new file mode 100644
index 000000000000..d4b49fc8f9dd
--- /dev/null
+++ b/net/fping/files/patch-src_fping.c
@@ -0,0 +1,11 @@
+--- src/fping.c.orig 2019-02-19 20:54:45 UTC
++++ src/fping.c
+@@ -427,7 +427,7 @@ int main(int argc, char** argv)
+ while ((c = optparse_long(&optparse_state, longopts, NULL)) != EOF) {
+ switch (c) {
+ case '4':
+- if (hints_ai_family != AF_UNSPEC) {
++ if (hints_ai_family == AF_INET6) {
+ fprintf(stderr, "%s: can't specify both -4 and -6\n", prog);
+ exit(1);
+ }