|
|
@ -183,9 +183,9 @@ PartitionCoreModule::deletePartition( Device* device, Partition* partition )
|
|
|
|
// I am not sure if we can iterate on Partition::children() while
|
|
|
|
// I am not sure if we can iterate on Partition::children() while
|
|
|
|
// deleting them, so let's play it safe and keep our own list.
|
|
|
|
// deleting them, so let's play it safe and keep our own list.
|
|
|
|
QList< Partition* > lst;
|
|
|
|
QList< Partition* > lst;
|
|
|
|
for ( auto partition : partition->children() )
|
|
|
|
for ( auto childPartition : partition->children() )
|
|
|
|
if ( !PMUtils::isPartitionFreeSpace( partition ) )
|
|
|
|
if ( !PMUtils::isPartitionFreeSpace( childPartition ) )
|
|
|
|
lst << partition;
|
|
|
|
lst << childPartition;
|
|
|
|
|
|
|
|
|
|
|
|
for ( auto partition : lst )
|
|
|
|
for ( auto partition : lst )
|
|
|
|
deletePartition( device, partition );
|
|
|
|
deletePartition( device, partition );
|
|
|
|