]> git.ipfire.org Git - thirdparty/openvpn.git/commit
Always release dhcp address in close_tun() on Windows.
authorSelva Nair <selva.nair@gmail.com>
Tue, 3 Jan 2017 20:38:03 +0000 (15:38 -0500)
committerGert Doering <gert@greenie.muc.de>
Mon, 9 Jan 2017 19:49:47 +0000 (20:49 +0100)
commit139cd1b14c57501bee36c1ec1dc5a037617ec29e
tree3142cd32cee8f10c0d1896dc24f86ac029cfa096
parent6650911256b2e636b4a2d754cfe60e949f213f91
Always release dhcp address in close_tun() on Windows.

Also make sure --dhcp-pre-release results in not just dhcp_release()
in open_tun() but a subsequent dhcp_renew() as well. Else dhcp transaction
gets aborted as this call to release() happens after the adapter status
is changed to connected.

Fixes Trac #807 (but can't say the same for Trac #665 without knowing
how to reproduce it)

v2: Mark --dhcp-release as obsolete in manpage and option parser, and
remove the unused dhcp_release variable.
Enforce dhcp-renew with dhcp-pre-release while parsing the option
instead of in open_tun().

Trac: #807

Signed-off-by: Selva Nair <selva.nair@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <1483475883-17450-1-git-send-email-selva.nair@gmail.com>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg13814.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
(cherry picked from commit db5b9b45508ea8f66ea80565279af3edd9300499)
doc/openvpn.8
src/openvpn/options.c
src/openvpn/tun.c
src/openvpn/tun.h