git: 111b60a2fddc - stable/13 - local-unbound: Read a tab separated resolv.conf
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 26 Nov 2025 15:35:50 UTC
The branch stable/13 has been updated by jlduran:
URL: https://cgit.FreeBSD.org/src/commit/?id=111b60a2fddca6051c6e782c4a9a4da258ed4cdf
commit 111b60a2fddca6051c6e782c4a9a4da258ed4cdf
Author: Jose Luis Duran <jlduran@FreeBSD.org>
AuthorDate: 2025-11-19 01:09:58 +0000
Commit: Jose Luis Duran <jlduran@FreeBSD.org>
CommitDate: 2025-11-26 15:34:23 +0000
local-unbound: Read a tab separated resolv.conf
Use [[:space:]] rather than a white space character to delimit the keys
and the values in the resolv.conf file.
PR: 236079
Reviewed by: des
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D53811
(cherry picked from commit 0628400590e025b7db1c0905e6ee488a24ef3f60)
---
usr.sbin/unbound/setup/local-unbound-setup.sh | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/usr.sbin/unbound/setup/local-unbound-setup.sh b/usr.sbin/unbound/setup/local-unbound-setup.sh
index 90e255204135..c15ce96e1cfe 100755
--- a/usr.sbin/unbound/setup/local-unbound-setup.sh
+++ b/usr.sbin/unbound/setup/local-unbound-setup.sh
@@ -118,8 +118,8 @@ set_chrootdir() {
get_nameservers() {
while read line ; do
local bareline=${line%%\#*}
- local key=${bareline%% *}
- local value=${bareline#* }
+ local key=${bareline%%[[:space:]]*}
+ local value=${bareline#*[[:space:]]}
case ${key} in
nameserver)
case ${value} in
@@ -145,8 +145,8 @@ gen_resolv_conf() {
local edns0=no
while read line ; do
local bareline=${line%%\#*}
- local key=${bareline%% *}
- local value=${bareline#* }
+ local key=${bareline%%[[:space:]]*}
+ local value=${bareline#*[[:space:]]}
case ${key} in
nameserver)
case ${value} in