git: b0df36580d5b - main - etcupdate: Remove the old pre-world tree when rotating for -p.
John Baldwin
jhb at FreeBSD.org
Fri Apr 23 16:45:04 UTC 2021
The branch main has been updated by jhb:
URL: https://cgit.FreeBSD.org/src/commit/?id=b0df36580d5b0df67a0f58ded8f6356b268f7f71
commit b0df36580d5b0df67a0f58ded8f6356b268f7f71
Author: John Baldwin <jhb at FreeBSD.org>
AuthorDate: 2021-04-23 16:40:04 +0000
Commit: John Baldwin <jhb at FreeBSD.org>
CommitDate: 2021-04-23 16:44:18 +0000
etcupdate: Remove the old pre-world tree when rotating for -p.
This fixes a bug in an earlier change to move tree rotation to
the end of the update where the step to make room for the new
preworld tree was deleting the old "current" tree instead of
the old "preworld" tree.
Reported by: olivier, dhw
Fixes: 0611aec3cf3a373e6a06f103699dbc91c3d6d472
MFC after: 2 weeks
---
usr.sbin/etcupdate/etcupdate.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/usr.sbin/etcupdate/etcupdate.sh b/usr.sbin/etcupdate/etcupdate.sh
index bb9eb00bc646..254a72abae08 100755
--- a/usr.sbin/etcupdate/etcupdate.sh
+++ b/usr.sbin/etcupdate/etcupdate.sh
@@ -1644,7 +1644,7 @@ EOF
if [ -z "$preworld" ]; then
panic "New tree should be rotated to old"
fi
- if ! remove_tree $old; then
+ if ! remove_tree $new; then
echo "Unable to remove previous pre-world tree."
exit 1
fi
More information about the dev-commits-src-all
mailing list