Jiří Moskovčák has uploaded a new change for review. Change subject: core: fixed NPE when vdsm returns emtpy balloon info ......................................................................
core: fixed NPE when vdsm returns emtpy balloon info Bug-Url: https://bugzilla.redhat.com/1171491 Change-Id: Ieb2b479e216610a0372f1c2542d268cb1f898f4c Signed-off-by: Jiri Moskovcak <jmosk...@redhat.com> --- M backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VdsUpdateRunTimeInfo.java 1 file changed, 4 insertions(+), 2 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/66/36066/1 diff --git a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VdsUpdateRunTimeInfo.java b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VdsUpdateRunTimeInfo.java index 7e8aced..c8a3f6b 100644 --- a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VdsUpdateRunTimeInfo.java +++ b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VdsUpdateRunTimeInfo.java @@ -1477,8 +1477,10 @@ if (_vmDict.get(vmId) == null) { continue; // if vm is unknown - continue } - - if (balloonInfo.getBalloonLastMemory() == 0) { // first time we check, so we don't have enough data yet + /* last memory is null the first time we check it or when + we're not getting the balloon info from vdsm + */ + if (balloonInfo.getBalloonLastMemory() == null || balloonInfo.getBalloonLastMemory() == 0) { balloonInfo.setBalloonLastMemory(balloonInfo.getCurrentMemory()); continue; } -- To view, visit http://gerrit.ovirt.org/36066 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ieb2b479e216610a0372f1c2542d268cb1f898f4c Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: ovirt-engine-3.5 Gerrit-Owner: Jiří Moskovčák <jmosk...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches