This makes the down script work both as regular down script as well as with the
down-root plugin. The up script is just changed for consistency.

Signed-off-by: Conrad Hoffmann <c...@bitfehler.net>
---
 contrib/pull-resolv-conf/client.down | 2 +-
 contrib/pull-resolv-conf/client.up   | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/contrib/pull-resolv-conf/client.down 
b/contrib/pull-resolv-conf/client.down
index 05f2d4d5..90bc5891 100644
--- a/contrib/pull-resolv-conf/client.down
+++ b/contrib/pull-resolv-conf/client.down
@@ -37,7 +37,7 @@
 PATH=/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin
 
 if type resolvconf >/dev/null 2>&1; then
-  resolvconf -d "${1}" -f
+  resolvconf -d "${dev}" -f
 elif [ -e /etc/resolv.conf.ovpnsave ] ; then
   # cp + rm rather than mv in case it's a symlink
   cp /etc/resolv.conf.ovpnsave /etc/resolv.conf
diff --git a/contrib/pull-resolv-conf/client.up 
b/contrib/pull-resolv-conf/client.up
index 8858b476..260c038e 100644
--- a/contrib/pull-resolv-conf/client.up
+++ b/contrib/pull-resolv-conf/client.up
@@ -87,11 +87,11 @@ elif [ $ndoms -gt 1 ]; then
 fi
 
 # This is the complete file - "$domains" has a leading space already
-out="# resolv.conf autogenerated by ${0} (${1})${nl}${dns}${ds}${domains}"
+out="# resolv.conf autogenerated by ${0} (${dev})${nl}${dns}${ds}${domains}"
 
 # use resolvconf if it's available
 if type resolvconf >/dev/null 2>&1; then
-  printf "%s\n" "${out}" | resolvconf -p -a "${1}"
+  printf "%s\n" "${out}" | resolvconf -p -a "${dev}"
 else
   # Preserve the existing resolv.conf
   if [ -e /etc/resolv.conf ] ; then
-- 
2.13.3


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Openvpn-devel mailing list
Openvpn-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openvpn-devel

Reply via email to