[blivet/master][PATCH] req_max_size is not a Size instance (#1077163)

David Lehman dlehman at redhat.com
Mon Mar 17 15:39:18 UTC 2014


On Mon, 2014-03-17 at 13:30 +0100, Vratislav Podzimek wrote:
> req_max_size is an int value in mebibytes, so we shouldn't try to do any

req_max_size should be a Size instance. If it isn't, please fix that
instead.

> conversion. The int() call is just to make it use the same code as the surround
> lines.
> 
> Signed-off-by: Vratislav Podzimek <vpodzime at redhat.com>
> ---
>  blivet/devices.py | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/blivet/devices.py b/blivet/devices.py
> index 9e6efb4..91686c9 100644
> --- a/blivet/devices.py
> +++ b/blivet/devices.py
> @@ -2811,7 +2811,7 @@ class LVMLogicalVolumeDevice(DMDevice):
>              data.grow = self.req_grow
>              if self.req_grow:
>                  data.size = int(self.req_size)
> -                data.maxSizeMB = self.req_max_size.convertTo(spec="mib")
> +                data.maxSizeMB = int(self.req_max_size)
>              else:
>                  data.size = int(self.size)
>  




More information about the anaconda-patches mailing list