summaryrefslogtreecommitdiffstats
path: root/partIntfHelpers.py
diff options
context:
space:
mode:
authorDavid Cantrell <dcantrell@redhat.com>2009-02-12 09:37:07 -1000
committerDavid Cantrell <dcantrell@redhat.com>2009-02-12 11:29:24 -1000
commit501b1cf15a48973a0dbab735d89026a512760ec0 (patch)
tree180808e3d85c308e760a38d3bfd99a2947868427 /partIntfHelpers.py
parent7554d826252c21b247e2baf11d2a89233c9ec336 (diff)
downloadanaconda-501b1cf15a48973a0dbab735d89026a512760ec0.tar.gz
anaconda-501b1cf15a48973a0dbab735d89026a512760ec0.tar.xz
anaconda-501b1cf15a48973a0dbab735d89026a512760ec0.zip
Removed partedUtils.get_partition_by_name()
Now provided by pyparted as parted.getPartitionByName()
Diffstat (limited to 'partIntfHelpers.py')
-rw-r--r--partIntfHelpers.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/partIntfHelpers.py b/partIntfHelpers.py
index 0b1108e7e..2766970c8 100644
--- a/partIntfHelpers.py
+++ b/partIntfHelpers.py
@@ -254,7 +254,7 @@ def doDeletePartitionsByDevice(intf, requestlist, diskset, device,
# get list of unique IDs of these requests
reqIDs = []
for req in requests:
- part = partedUtils.get_partition_by_name(diskset.disks, req.device)
+ part = parted.getPartitionByName(req.device)
if part.type & parted.PARTITION_FREESPACE or part.type & parted.PARTITION_METADATA or part.type & parted.PARTITION_PROTECTED:
continue
reqIDs.append(req.uniqueID)
@@ -265,7 +265,7 @@ def doDeletePartitionsByDevice(intf, requestlist, diskset, device,
req = requestlist.getRequestByID(id)
if req is None:
continue
- part = partedUtils.get_partition_by_name(diskset.disks, req.device)
+ part = parted.getPartitionByName(req.device)
rc = doDeletePartitionByRequest(intf, requestlist, part,
confirm=0, quiet=1)
if not rc:
@@ -280,7 +280,7 @@ def doDeletePartitionsByDevice(intf, requestlist, diskset, device,
# get list of unique IDs of these requests
leftIDs = []
for req in left_requests:
- part = partedUtils.get_partition_by_name(diskset.disks, req.device)
+ part = parted.getPartitionByName(req.device)
if part.type & parted.PARTITION_FREESPACE or part.type & parted.PARTITION_METADATA or part.type & parted.PARTITION_PROTECTED:
continue
leftIDs.append(req.uniqueID)
@@ -380,8 +380,7 @@ def checkForSwapNoMatch(anaconda):
if not request.device or not request.fstype:
continue
- part = partedUtils.get_partition_by_name(anaconda.id.diskset.disks,
- request.device)
+ part = parted.getPartitionByName(request.device)
if (part and (not part.type & parted.PARTITION_FREESPACE)
and (part.native_type == 0x82)
and (request.fstype and request.fstype.getName() != "swap")