[Kimchi-devel] [PATCH v3 2/5] Handle invalid path in 'get_disk_ref_cnt'
Aline Manera
alinefm at linux.vnet.ibm.com
Fri May 15 15:19:25 UTC 2015
Reviewed-by: Aline Manera <alinefm at linux.vnet.ibm.com>
On 12/05/2015 11:58, Crístian Deives wrote:
> Signed-off-by: Crístian Deives <cristiandeives at gmail.com>
> ---
> src/kimchi/model/diskutils.py | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/kimchi/model/diskutils.py b/src/kimchi/model/diskutils.py
> index 1d575cb..97fc9d9 100644
> --- a/src/kimchi/model/diskutils.py
> +++ b/src/kimchi/model/diskutils.py
> @@ -34,7 +34,7 @@ def get_disk_ref_cnt(objstore, conn, path):
> with objstore as session:
> try:
> ref_cnt = session.get('storagevolume', path)['ref_cnt']
> - except NotFoundError:
> + except (KeyError, NotFoundError):
> kimchi_log.info('Volume %s not found in obj store.' % path)
> ref_cnt = 0
> # try to find this volume in existing vm
More information about the Kimchi-devel
mailing list