Change in vdsm[master]: vm: remove obfuscated use of errCode
fromani at redhat.com
fromani at redhat.com
Fri Mar 6 08:07:26 UTC 2015
Francesco Romani has posted comments on this change.
Change subject: vm: remove obfuscated use of errCode
......................................................................
Patch Set 4:
(1 comment)
https://gerrit.ovirt.org/#/c/38267/4/vdsm/virt/vm.py
File vdsm/virt/vm.py:
Line 3740: diskelem.toxml(), libvirt.VIR_DOMAIN_DEVICE_MODIFY_FORCE)
Line 3741: except Exception:
Line 3742: self.log.debug("updateDeviceFlags failed", exc_info=True)
Line 3743: self.cif.teardownVolumePath(drivespec)
Line 3744: return errCode['changeDisk']
> The old code was creating new dict for this error - safe. You return the sh
Right. I made this patch for the sake of consinstency[1] in the first place, but since it is just adding noise and make the code unsafer, I'll just abandon it
+++
[1] To make the use of errCode consistently bad all across vm.py, with the only goal to make the review of followup patch a little easier.
Line 3745: if vmDev in self.conf:
Line 3746: self.cif.teardownVolumePath(self.conf[vmDev])
Line 3747:
Line 3748: self.conf[vmDev] = path
--
To view, visit https://gerrit.ovirt.org/38267
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I5944a3ac9433fa3c85879f4a16b5b6730c2b50b6
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
More information about the vdsm-patches
mailing list