From 8169eb66832101444b0a824c932982966222097c Mon Sep 17 00:00:00 2001 From: Mandell Degerness Date: Thu, 21 Feb 2013 02:59:44 +0000 Subject: [PATCH] Skip timestamp check if 'capabilities' is none fix bug: #1131011 Change-Id: I6266560627d03d95862a7f2c85ac63e2e9daef6b --- cinder/scheduler/host_manager.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cinder/scheduler/host_manager.py b/cinder/scheduler/host_manager.py index 66926f215..2392de859 100644 --- a/cinder/scheduler/host_manager.py +++ b/cinder/scheduler/host_manager.py @@ -116,10 +116,10 @@ class HostState(object): def update_from_volume_capability(self, capability): """Update information about a host from its volume_node info.""" - if self.updated and self.updated > capability['timestamp']: - return - if capability: + if self.updated and self.updated > capability['timestamp']: + return + self.volume_backend = capability.get('volume_backend_name', None) self.vendor_name = capability.get('vendor_name', None) self.driver_version = capability.get('driver_version', None) -- 2.45.2