Bug 251961

Summary: /etc/periodic/daily/221.backup-gpart: daily_backup_gpart_exclude doesn't work properly
Product: Base System Reporter: Kan Sasaki <sasaki12>
Component: confAssignee: Ed Maste <emaste>
Status: Closed FIXED    
Severity: Affects Only Me CC: emaste
Priority: ---    
Version: 12.2-STABLE   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
patch for 221.backup-gpart none

Description Kan Sasaki 2020-12-19 13:31:42 UTC
Created attachment 220718 [details]
patch for 221.backup-gpart

Since gpart_devs is not quoted, if daily_backup_gpart_exclude matches something, gpart_devs will be empty.
Comment 1 Ed Maste freebsd_committer freebsd_triage 2020-12-19 19:40:56 UTC
I'll pick this up
Comment 2 commit-hook freebsd_committer freebsd_triage 2020-12-27 00:28:24 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/src/commit/?id=93900fc697992f893e2e69dce0c2f67b1f66a774

commit 93900fc697992f893e2e69dce0c2f67b1f66a774
Author:     Ed Maste <emaste@FreeBSD.org>
AuthorDate: 2020-12-27 00:24:18 +0000
Commit:     Ed Maste <emaste@FreeBSD.org>
CommitDate: 2020-12-27 00:27:12 +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
    MFC after:      1 week

 usr.sbin/periodic/etc/daily/221.backup-gpart | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Comment 3 commit-hook freebsd_committer freebsd_triage 2021-01-04 18:48:35 UTC
A commit in branch stable/12 references this bug:

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(-)
Comment 4 Ed Maste freebsd_committer freebsd_triage 2021-01-04 18:50:47 UTC
Fixed in main and stable/12 now, thank you for the report and fix!