Skip to contentSkip to conversation

Fixed that "--bind ipv6only" did not work due to incorrect parameter processing. It seems that "ipv6only" did not work from the beginning.

PATCH In review hashiz 2 participants 2 messages Sep 28, 2017 – Sep 30, 2017

lore
Share & tools
lore

hashiz

author
#0 lore raw

PATCH 1/1 Fixed that "--bind ipv6only" did not work due to incorrect parameter processing. It seems that "ipv6only" did not work from the beginning.

---
 src/openvpn/options.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
src/openvpn/options.c +1 -1
index 3a5bccfc..5f31e7eb 100644
@@ -5881,7 +5881,7 @@ add_option(struct options *options,
         VERIFY_PERMISSION(OPT_P_GENERAL|OPT_P_CONNECTION);
         options->ce.remote_port = p[1];
     }
-    else if (streq(p[0], "bind") && !p[1])
+    else if (streq(p[0], "bind") && !p[2])
     {
         VERIFY_PERMISSION(OPT_P_GENERAL|OPT_P_CONNECTION);
         options->ce.bind_defined = true;
Signature · 1 line
2.11.0
Acked-by on v1 1/1
#1 lore raw

ACK, thanks.

I have modified the commit message to refer to the commit that broke this, and added a short first line (which is what shows up in "git shortlog", so you want this to be less than ~60-70 charcters, not multilien).

Your patch has been applied to the master and release/2.4 branch.

commit cdeba63ca3a9e5c765edecd11745e9e2cc1b945d (master) commit b0ef0003c554db34f5623a920874c97b22bc0224 (release/2.4)

Author: hashiz <[email protected]...>
Date:   Thu Sep 28 12:16:20 2017 +0900

Fix '--bind ipv6only'

Commit 3d6a4cded2b20fb81 introduced checking for "too many parameters" at option processing, and neglected to take "ipv6only" as possible (and optional) argument to "--bind" into account.

Trac: #938

Message-Id: <[email protected]...>
URL: https://www.mail-archive.com/[email protected]/msg15522.html

--
kind regards,