diff mbox series

[ovs-dev] ovn-northd.at: Fix MSYS IPv6 interpretation

Message ID 20180110193411.9724-1-aserdean@ovn.org
State Accepted
Headers show
Series [ovs-dev] ovn-northd.at: Fix MSYS IPv6 interpretation | expand

Commit Message

Alin-Gabriel Serdean Jan. 10, 2018, 7:34 p.m. UTC
Similar to commit 847dc1c22c0b4af2ba33d15c311be32d34257429, MSYS mangles the
IPv6 address:
'ovn-nbctl: ro-sw: invalid network address: aef0;1\64'

This patch uses the full form of the IPv6 address instead of its shorter
notation.

Signed-off-by: Alin Gabriel Serdean <aserdean@ovn.org>
---
 tests/ovn-northd.at | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Ben Pfaff Jan. 10, 2018, 9:16 p.m. UTC | #1
On Wed, Jan 10, 2018 at 09:34:11PM +0200, Alin Gabriel Serdean wrote:
> Similar to commit 847dc1c22c0b4af2ba33d15c311be32d34257429, MSYS mangles the
> IPv6 address:
> 'ovn-nbctl: ro-sw: invalid network address: aef0;1\64'
> 
> This patch uses the full form of the IPv6 address instead of its shorter
> notation.
> 
> Signed-off-by: Alin Gabriel Serdean <aserdean@ovn.org>

Acked-by: Ben Pfaff <blp@ovn.org>

Is there a regular expression (etc.) that could find these problems?  If
so, then we could add a build-time check that flags them before they get
into the tree, or we could add something to checkpatch to find them at
review time.
Alin-Gabriel Serdean Jan. 11, 2018, 2:48 p.m. UTC | #2
> -----Original Message-----
> From: Ben Pfaff [mailto:blp@ovn.org]
> Sent: Wednesday, January 10, 2018 11:16 PM
> To: Alin Gabriel Serdean <aserdean@ovn.org>
> Cc: dev@openvswitch.org
> Subject: Re: [ovs-dev] [PATCH] ovn-northd.at: Fix MSYS IPv6 interpretation
> 
> On Wed, Jan 10, 2018 at 09:34:11PM +0200, Alin Gabriel Serdean wrote:
> > Similar to commit 847dc1c22c0b4af2ba33d15c311be32d34257429, MSYS
> > mangles the
> > IPv6 address:
> > 'ovn-nbctl: ro-sw: invalid network address: aef0;1\64'
> >
> > This patch uses the full form of the IPv6 address instead of its
> > shorter notation.
> >
> > Signed-off-by: Alin Gabriel Serdean <aserdean@ovn.org>
> 
> Acked-by: Ben Pfaff <blp@ovn.org>
> 
> Is there a regular expression (etc.) that could find these problems?  If
so,
> then we could add a build-time check that flags them before they get into
> the tree, or we could add something to checkpatch to find them at review
> time.
[Alin Serdean] Thanks for the quick review, applied on master.
Thanks for the suggestion, I'll try to see what I can come up with.
I would rather switch to msys2 because you can add MSYS2_ARG_CONV_EXCL
to bypass the argument mangling
(https://github.com/msys2/msys2/wiki/Porting#filesystem-namespaces),
making things much cleaner.
Unfortunately this is not present on MSYS.
diff mbox series

Patch

diff --git a/tests/ovn-northd.at b/tests/ovn-northd.at
index b2bb7e3..baa2add 100644
--- a/tests/ovn-northd.at
+++ b/tests/ovn-northd.at
@@ -157,7 +157,7 @@  AT_SETUP([ovn -- check IPv6 RA config propagation to SBDB])
 ovn_start
 
 ovn-nbctl lr-add ro
-ovn-nbctl lrp-add ro ro-sw 00:00:00:00:00:01 aef0::1/64
+ovn-nbctl lrp-add ro ro-sw 00:00:00:00:00:01 aef0:0:0:0:0:0:0:1/64
 ovn-nbctl ls-add sw
 ovn-nbctl lsp-add sw sw-ro
 ovn-nbctl lsp-set-type sw-ro router