Attention is currently required from: flichtenheld, plaisthos.

Hello plaisthos, flichtenheld,

I'd like you to do a code review.
Please visit

    http://gerrit.openvpn.net/c/openvpn/+/423?usp=email

to review the following change.


Change subject: Make --dns options apply for tap-windows6 driver
......................................................................

Make --dns options apply for tap-windows6 driver

When tap-windows6 driver is used, both --dhcp-option and
--dns options are applied with DHCP. When processing --dns options,
we don't set "tuntap_options.dhcp_options" member, which is required
for DHCP string to be sent to the driver. As a result, --dns options
are not applied at all.

Fix by adding missing assignment of tuntap_options.dhcp_options.

Fixes https://github.com/OpenVPN/openvpn/issues/447

Change-Id: I24f43ad319bd1ca530fe17442d02a97412eb75c7
Signed-off-by: Lev Stipakov <l...@openvpn.net>
---
M src/openvpn/options.c
1 file changed, 6 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/23/423/1

diff --git a/src/openvpn/options.c b/src/openvpn/options.c
index 631ac73..e793a96 100644
--- a/src/openvpn/options.c
+++ b/src/openvpn/options.c
@@ -8014,6 +8014,9 @@
         if (streq(p[1], "search-domains") && p[2])
         {
             dns_domain_list_append(&options->dns_options.search_domains, 
&p[2], &options->dns_options.gc);
+#ifdef _WIN32
+            options->tuntap_options.dhcp_options |= DHCP_OPTIONS_DHCP_REQUIRED;
+#endif
         }
         else if (streq(p[1], "server") && p[2] && p[3] && p[4])
         {
@@ -8090,6 +8093,9 @@
                 msg(msglevel, "--dns server %ld: unknown option type '%s' or 
missing or unknown parameter", priority, p[3]);
                 goto err;
             }
+#ifdef _WIN32
+            options->tuntap_options.dhcp_options |= DHCP_OPTIONS_DHCP_OPTIONAL;
+#endif
         }
         else
         {

--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/423?usp=email
To unsubscribe, or for help writing mail filters, visit 
http://gerrit.openvpn.net/settings

Gerrit-Project: openvpn
Gerrit-Branch: release/2.6
Gerrit-Change-Id: I24f43ad319bd1ca530fe17442d02a97412eb75c7
Gerrit-Change-Number: 423
Gerrit-PatchSet: 1
Gerrit-Owner: stipa <lstipa...@gmail.com>
Gerrit-Reviewer: flichtenheld <fr...@lichtenheld.com>
Gerrit-Reviewer: plaisthos <arne-open...@rfc2549.org>
Gerrit-CC: openvpn-devel <openvpn-devel@lists.sourceforge.net>
Gerrit-Attention: plaisthos <arne-open...@rfc2549.org>
Gerrit-Attention: flichtenheld <fr...@lichtenheld.com>
Gerrit-MessageType: newchange
_______________________________________________
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel

Reply via email to