[blivet:master 06/11] Check whether type is mdbiosraidarray before checking smallest member (#1085474)

mulhern amulhern at redhat.com
Fri Apr 11 15:23:07 UTC 2014


Related: fed#1085474

Signed-off-by: mulhern <amulhern at redhat.com>
---
 blivet/devices.py | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/blivet/devices.py b/blivet/devices.py
index bc64812..53bfbe3 100644
--- a/blivet/devices.py
+++ b/blivet/devices.py
@@ -3286,15 +3286,15 @@ class MDRaidArrayDevice(ContainerDevice):
         """Returns the actual or estimated size depending on whether or
            not the array exists.
         """
-        smallestMember = self.smallestMember
-        if smallestMember is None:
-            return 0
-
         # For container members return probed size, as we cannot determine it
         # when teared down.
         if self.type == "mdbiosraidarray":
             return self._size
 
+        smallestMember = self.smallestMember
+        if smallestMember is None:
+            return 0
+
         smallestMemberSize = smallestMember.size - self.superBlockSize
         if not self.exists or not self.partedDevice:
             try:
-- 
1.8.3.1



More information about the anaconda-patches mailing list