From: Jean-Baptiste RANSY Date: Thu, 21 Mar 2013 10:51:37 +0000 (+0100) Subject: CoraidDriver: typo in _login exception handler X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=4403230bbe8f39a19c38e58840bbb2283ccd808f;p=openstack-build%2Fcinder-build.git CoraidDriver: typo in _login exception handler In cinder/volume/drivers/coraid.py, _login method, if login is unsuccessful, we try to get the message from an undefined object "response". Instead we should be getting it from "reply". - errmsg = response.get('message', '') + errmsg = reply.get('message', '') Fixes bug 1157499 Change-Id: Ifd047ced6b40f49881e81d4e73189d9bd216c903 --- diff --git a/cinder/volume/drivers/coraid.py b/cinder/volume/drivers/coraid.py index 260a48aea..549a2ea3c 100644 --- a/cinder/volume/drivers/coraid.py +++ b/cinder/volume/drivers/coraid.py @@ -98,7 +98,7 @@ class CoraidRESTClient(object): LOG.debug(msg % dict(session=self.session)) return True else: - errmsg = response.get('message', '') + errmsg = reply.get('message', '') msg = _('Message : %(message)s') raise CoraidESMException(msg % dict(message=errmsg)) return True