diff options
author | Andrew Gaffney <agaffney@gentoo.org> | 2006-03-16 19:24:37 +0000 |
---|---|---|
committer | Andrew Gaffney <agaffney@gentoo.org> | 2006-03-16 19:24:37 +0000 |
commit | f9505e3d00ab110c35c9c1589e54f1f3dfad3dfc (patch) | |
tree | 41c14112391b35e7d3fa3c7fe4f2f1f6f1f3b422 /src/templates | |
parent | minor updates for new GLISD code (diff) | |
download | gli-f9505e3d00ab110c35c9c1589e54f1f3dfad3dfc.tar.gz gli-f9505e3d00ab110c35c9c1589e54f1f3dfad3dfc.tar.bz2 gli-f9505e3d00ab110c35c9c1589e54f1f3dfad3dfc.zip |
src/templates/x86ArchitectureTemplate.py:
fail if any filesystems are mounted on the device being partitioned
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/gli/trunk@1369 f8877401-5920-0410-a79b-8e2d7e04ca0d
Diffstat (limited to 'src/templates')
-rw-r--r-- | src/templates/x86ArchitectureTemplate.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/templates/x86ArchitectureTemplate.py b/src/templates/x86ArchitectureTemplate.py index d0648f1..55b16e5 100644 --- a/src/templates/x86ArchitectureTemplate.py +++ b/src/templates/x86ArchitectureTemplate.py @@ -5,7 +5,7 @@ # of which can be found in the main directory of this project. Gentoo Linux Installer -$Id: x86ArchitectureTemplate.py,v 1.115 2006/03/16 19:10:55 agaffney Exp $ +$Id: x86ArchitectureTemplate.py,v 1.116 2006/03/16 19:24:37 agaffney Exp $ Copyright 2004 Gentoo Technologies Inc. @@ -112,6 +112,9 @@ class x86ArchitectureTemplate(ArchitectureTemplate): self._logger.log("partitioning: Processing " + device + "...") + if GLIUtility.spawn("mount | grep '^" + device + "'", return_output=True)[1].strip(): + raise GLIException("PartitionsMountedError", 'fatal', 'partition', "Cannot partition " + device + " due to filesystems being mounted") + # Create pyparted objects for this device parted_dev = parted.PedDevice.get(device) try: |