calamares/calamares-3.2.15-skip-partition-if-minsize-less-than-available-size.patch

16 lines
653 B
Diff

--- calamares-3.2.15/src/modules/partition/core/PartitionLayout.cpp.orig 2019-10-12 12:00:31.660000000 +0200
+++ calamares-3.2.15/src/modules/partition/core/PartitionLayout.cpp 2019-10-12 12:01:10.894000000 +0200
@@ -179,6 +179,12 @@
else
minSize = 0;
+ if ( availableSize < 5 * 1024 * 1024) {
+ cWarning() << "Partition" << part.partMountPoint << "available size"
+ << "is insufficient to add partition, skipping...";
+ continue;
+ }
+
if ( part.partMaxSize.isValid() )
maxSize = part.partMaxSize.toSectors( totalSize, dev->logicalSize() );
else