Package: openvpn
Version: 2.1.3-2
Severity: minor
Tags: patch
User: [email protected]
Usertags: origin-ubuntu natty ubuntu-patch
* update-resolv-conf: Correctly handle multiple dns search domains,
using the same logic as nameservers. Patch courtesy of Jeremy
Zawodny. (LP: #662847)
Thanks for considering the patch.
-- System Information:
Debian Release: squeeze/sid
APT prefers natty-updates
APT policy: (500, 'natty-updates'), (500, 'natty-security'), (500, 'natty')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.38-5-generic (SMP w/2 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
--- debian/update-resolv-conf 2010-10-18 10:13:00.934274005 -0700
+++ debian/update-resolv-conf 2010-10-18 10:19:23.914274005 -0700
@@ -32,15 +32,15 @@
IF_DNS_NAMESERVERS="$IF_DNS_NAMESERVERS $part3"
fi
if [ "$part2" == "DOMAIN" ] ; then
- IF_DNS_SEARCH="$part3"
+ IF_DNS_SEARCH="$IF_DNS_SEARCH $part3"
fi
fi
done
R=""
- if [ "$IF_DNS_SEARCH" ] ; then
- R="${R}search $IF_DNS_SEARCH
+ for SS in $IF_DNS_SEARCH ; do
+ R="${R}search $SS
"
- fi
+ done
for NS in $IF_DNS_NAMESERVERS ; do
R="${R}nameserver $NS
"