Kobi Ianko has uploaded a new change for review. Change subject: core: Potential NullPointerException at Entities.ObjectNames method ......................................................................
core: Potential NullPointerException at Entities.ObjectNames method The method accepts a list that could contain null elements. In case one or more of the elements in the list is null, an exception will be thrown. Change-Id: If282b7a525800ffcb9a6f73292f01de3fca810d0 Bug-Url: https://bugzilla.redhat.com/1063173 Signed-off-by: Kobi Ianko <k...@redhat.com> --- M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Entities.java 1 file changed, 3 insertions(+), 1 deletion(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/50/24250/1 diff --git a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Entities.java b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Entities.java index e636023..f91440b 100644 --- a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Entities.java +++ b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Entities.java @@ -79,7 +79,9 @@ if (entityList != null && !entityList.isEmpty()) { Set<String> names = new HashSet<String>(); for (E e : entityList) { - names.add(e.getName()); + if (e != null) { + names.add(e.getName()); + } } return names; } else { -- To view, visit http://gerrit.ovirt.org/24250 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: If282b7a525800ffcb9a6f73292f01de3fca810d0 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Kobi Ianko <k...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches