Ravi Nori has uploaded a new change for review. Change subject: core : Fix NPE in CommandBase buildCommandEntity ......................................................................
core : Fix NPE in CommandBase buildCommandEntity When execution context is null CommandBase buildCommandEntity throws a NPE. Change-Id: I6f6a2b7e0727a22a9649d0b305000f59eb4236a1 Bug-Url: https://bugzilla.redhat.com/1147971 Signed-off-by: Ravi Nori <rn...@redhat.com> --- M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java 1 file changed, 2 insertions(+), 2 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/52/33552/1 diff --git a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java index d2bf2fd..4af0ff3 100644 --- a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java +++ b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CommandBase.java @@ -2182,8 +2182,8 @@ private CommandEntity buildCommandEntity(Guid parentCommandId, boolean callBackEnabled) { return CommandEntity.buildCommandEntity(getCommandId(), parentCommandId, - getExecutionContext().getJob() == null ? Guid.Empty : getExecutionContext().getJob().getId(), - getExecutionContext().getStep() == null ? Guid.Empty : getExecutionContext().getStep().getId(), + getExecutionContext() == null || getExecutionContext().getJob() == null ? Guid.Empty : getExecutionContext().getJob().getId(), + getExecutionContext() == null || getExecutionContext().getStep() == null ? Guid.Empty : getExecutionContext().getStep().getId(), getActionType(), getParameters(), commandStatus, -- To view, visit http://gerrit.ovirt.org/33552 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I6f6a2b7e0727a22a9649d0b305000f59eb4236a1 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Ravi Nori <rn...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches