This is just some leftovers from the last time I fixed the tracking of the free region and it's containing disk. --- storage/partitioning.py | 22 +++++++++++----------- 1 files changed, 11 insertions(+), 11 deletions(-) diff --git a/storage/partitioning.py b/storage/partitioning.py index cf151d1..5b9e02b 100644 --- a/storage/partitioning.py +++ b/storage/partitioning.py @@ -653,21 +653,21 @@ def allocatePartitions(disks, partitions): part_type == parted.PARTITION_NORMAL: # see if we can do better with a logical partition log.debug("not enough free space for primary -- trying logical") - part_type = getNextPartitionType(disk, no_primary=True) - if part_type: - free = getBestFreeSpaceRegion(disk, + new_part_type = getNextPartitionType(disk, no_primary=True) + if new_part_type: + best = getBestFreeSpaceRegion(disk, part_type, _part.req_size, best_free=free, boot=_part.req_bootable) - elif best: - if free != best: - # now we know we are choosing a new free space, - # so update the disk and part type - log.debug("updating use_disk to %s (%s), type: %s" - % (_disk, _disk.name, new_part_type)) - part_type = new_part_type - use_disk = _disk + + if best and free != best: + # now we know we are choosing a new free space, + # so update the disk and part type + log.debug("updating use_disk to %s (%s), type: %s" + % (_disk, _disk.name, new_part_type)) + part_type = new_part_type + use_disk = _disk log.debug("new free: %s (%d-%d / %dMB)" % (best, best.start, best.end, -- 1.6.0.6 _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list