From: cinap_lenrek@felloff.net
To: 9front@9front.org
Subject: Re: [9front] ip/ping -6
Date: Sun, 18 Jun 2017 05:22:43 +0200 [thread overview]
Message-ID: <10A01C6A6B34BCF166A7C0F5AA347CD1@felloff.net> (raw)
In-Reply-To: 52D3C07F-3CA0-45A6-8125-1011808C3210@gmail.com
untested patch, filters out v4/v6 for icmpv6/icmp and il
--- a/sys/src/cmd/ndb/cs.c Thu Jun 15 15:59:02 2017 +0000
+++ b/sys/src/cmd/ndb/cs.c Sun Jun 18 05:19:48 2017 +0200
@@ -1525,8 +1525,12 @@
snprint(reply, sizeof(reply), "%s/%s/clone %s%s",
mntpt, np->net, ts, x);
else {
- /* il only supports ipv4 addresses */
- if(strcmp(np->net, "il") == 0 && !isv4str(t->val))
+ /* il and icmp only supports ipv4 addresses */
+ if((strcmp(np->net, "il") == 0 || strcmp(np->net, "icmp") == 0) && !isv4str(t->val))
+ return nil;
+
+ /* icmpv6 does not support ipv4 addresses */
+ if(strcmp(np->net, "icmpv6") == 0 && isv4str(t->val))
return nil;
snprint(reply, sizeof(reply), "%s/%s/clone %s!%s%s%s",
--
cinap
next reply other threads:[~2017-06-18 3:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-18 3:22 cinap_lenrek [this message]
2017-06-18 4:33 ` Kenji Arisawa
-- strict thread matches above, loose matches on Subject: below --
2017-06-18 3:03 cinap_lenrek
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=10A01C6A6B34BCF166A7C0F5AA347CD1@felloff.net \
--to=cinap_lenrek@felloff.net \
--cc=9front@9front.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).