diff options
author | Kris Kennaway <kris@FreeBSD.org> | 2004-09-26 21:59:48 +0000 |
---|---|---|
committer | Kris Kennaway <kris@FreeBSD.org> | 2004-09-26 21:59:48 +0000 |
commit | 82cb4888a470ae9f0411fa9ea390b68843ba6547 (patch) | |
tree | e2cd60d8e83ed9c74e9a400d879b7ea37207c209 /Tools | |
parent | Pull in portbuild.$(hostname) for per-client customization (diff) |
Refuse to "clean" / if something goes wrong upstream and we are passed
the wrong path
Approved by: portmgr (self)
Notes
Notes:
svn path=/head/; revision=118447
Diffstat (limited to 'Tools')
-rwxr-xr-x | Tools/portbuild/scripts/clean-chroot | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Tools/portbuild/scripts/clean-chroot b/Tools/portbuild/scripts/clean-chroot index 196dc373a5f3..a756ac31265b 100755 --- a/Tools/portbuild/scripts/clean-chroot +++ b/Tools/portbuild/scripts/clean-chroot @@ -8,6 +8,11 @@ noclean=$4 # directories to clean cleandirs="/usr/local /usr/X11R6 /compat /var/db/pkg" +if [ `realpath ${chroot}` = "/" ]; then + # Don't spam the root file system if something has gone wrong! + exit 1 +fi + #umount ${chroot}/proc if [ ${arch} = "i386" ]; then |