Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 4 Jan 2021 18:47:55 GMT
From:      Ed Maste <emaste@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 25e00a2894ea - stable/12 - Fix daily_backup_gpart_exclude in periodic daily 221.backup-gpart
Message-ID:  <202101041847.104IltI5019196@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/12 has been updated by emaste:

URL: https://cgit.FreeBSD.org/src/commit/?id=25e00a2894ea4ea2cbe64f25d9f3d99b60d1ea32

commit 25e00a2894ea4ea2cbe64f25d9f3d99b60d1ea32
Author:     Ed Maste <emaste@FreeBSD.org>
AuthorDate: 2020-12-27 00:24:18 +0000
Commit:     Ed Maste <emaste@FreeBSD.org>
CommitDate: 2021-01-04 18:47:46 +0000

    Fix daily_backup_gpart_exclude in periodic daily 221.backup-gpart
    
    Since gpart_devs was not quoted (losing embedded newlines), if
    daily_backup_gpart_exclude matched something, gpart_devs was empty.
    
    PR:             251961
    Submitted by:   Kan Sasaki
    
    (cherry picked from commit 93900fc697992f893e2e69dce0c2f67b1f66a774)
---
 usr.sbin/periodic/etc/daily/221.backup-gpart | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/usr.sbin/periodic/etc/daily/221.backup-gpart b/usr.sbin/periodic/etc/daily/221.backup-gpart
index d71bd8ffe12a..b2bfde820272 100755
--- a/usr.sbin/periodic/etc/daily/221.backup-gpart
+++ b/usr.sbin/periodic/etc/daily/221.backup-gpart
@@ -54,7 +54,7 @@ case "$daily_backup_gpart_enable" in
 
 	gpart_devs=$(gpart show | awk '$1 == "=>" { print $4 }')
 	if [ -n "$daily_backup_gpart_exclude" ]; then
-		gpart_devs=$(echo ${gpart_devs} | grep -E -v "${daily_backup_gpart_exclude}")
+		gpart_devs=$(echo "${gpart_devs}" | grep -E -v "${daily_backup_gpart_exclude}")
 	fi
 
 	if [ -z "$gpart_devs"  ]; then



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202101041847.104IltI5019196>