summaryrefslogtreecommitdiff
path: root/usr.sbin/mergemaster
diff options
context:
space:
mode:
authorJilles Tjoelker <jilles@FreeBSD.org>2014-04-14 22:01:49 +0000
committerJilles Tjoelker <jilles@FreeBSD.org>2014-04-14 22:01:49 +0000
commit819b4fd06a2106d4c2ccfe845af9ef7a71da66d6 (patch)
tree55fb781fdffbd74b49a3f80da22ea627530ab86f /usr.sbin/mergemaster
parent27e21758b8f6ca5ed9a5858990c4361a77ffdd6b (diff)
downloadsrc-test2-819b4fd06a2106d4c2ccfe845af9ef7a71da66d6.tar.gz
src-test2-819b4fd06a2106d4c2ccfe845af9ef7a71da66d6.zip
mergemaster: Avoid "/var/tmp/temproot disappeared" if there is nothing to
compare. Because of the change to find in SVN r253886, the entire temproot would be deleted if it became empty, leading to a confusing message "*** FATAL ERROR: The temproot directory ${TEMPROOT} has disappeared!" Note that mergemaster does not do anything useful in this situation anyway (e.g. put IGNORE_FILES="/etc/group /etc/master.passwd" in /etc/mergemaster.rc and run mergemaster -p). As noted in that commit, add -mindepth 1. PR: bin/188485 Submitted by: David Boyd MFC after: 1 week
Notes
Notes: svn path=/head/; revision=264480
Diffstat (limited to 'usr.sbin/mergemaster')
-rwxr-xr-xusr.sbin/mergemaster/mergemaster.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/mergemaster/mergemaster.sh b/usr.sbin/mergemaster/mergemaster.sh
index c5ed5fdfa26f..a200088b1194 100755
--- a/usr.sbin/mergemaster/mergemaster.sh
+++ b/usr.sbin/mergemaster/mergemaster.sh
@@ -709,7 +709,7 @@ case "${RERUN}" in
# and to make the actual comparison faster.
find ${TEMPROOT}/usr -type l -delete 2>/dev/null
find ${TEMPROOT} -type f -size 0 -delete 2>/dev/null
- find -d ${TEMPROOT} -type d -empty -delete 2>/dev/null
+ find -d ${TEMPROOT} -type d -empty -mindepth 1 -delete 2>/dev/null
# Build the mtree database in a temporary location.
case "${PRE_WORLD}" in