[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[master][rhel6-branch][PATCH] Re-get partedPartition after re-adding failed-to-remove partition.



This is a fix to commit 931ddf56bbc5cbc249d947dd86862c71a1bce7a7.

Related: rhbz#592339
Resolves: rhbz#602351
---
 storage/devices.py |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/storage/devices.py b/storage/devices.py
index 7e7e405..78460bb 100644
--- a/storage/devices.py
+++ b/storage/devices.py
@@ -1354,6 +1354,7 @@ class PartitionDevice(StorageDevice):
             self.disk.originalFormat.commit()
         except DiskLabelCommitError:
             self.disk.originalFormat.addPartition(self.partedPartition)
+            self.partedPartition = self.disk.originalFormat.partedDisk.getPartitionByPath(self.path)
             raise
 
         self.exists = False
-- 
1.6.6.1


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]