Moti Asayag has posted comments on this change.

Change subject: findbugs: Suspicious reference comparison of Boolean values
......................................................................


Patch Set 3: (1 inline comment)

....................................................
File 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/VmDevice.java
Line 248:                 && address.equals(other.address)
Line 249:                 && bootOrder == other.bootOrder
Line 250:                 && ObjectUtils.objectsEqual(specParams, 
other.specParams)
Line 251:                 && isManaged == other.isManaged
Line 252:                 && (isPlugged == null ? false : 
isPlugged.booleanValue()) == (other.isPlugged == null ? false : 
other.isPlugged.booleanValue())
More options:
  && ObjectUtils.objectsEqual(isPlugged , other.isPlugged 

  or

  && getIsPlugged().equals(other.getIsPlugged())

I'm in favor for the second, as getIsPlugged() has already the logic for the 
plugged property null safety
Line 253:                 && isReadOnly == other.isReadOnly
Line 254:                 && alias.equals(other.alias)
Line 255:                 && ObjectUtils.objectsEqual(customProperties, 
other.customProperties));
Line 256:     }


-- 
To view, visit http://gerrit.ovirt.org/15325
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I210767bb1e273caa421bf3da1b1608a7facb6621
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Shahar Havivi <shav...@redhat.com>
Gerrit-Reviewer: Moti Asayag <masa...@redhat.com>
Gerrit-Reviewer: Oved Ourfali <oourf...@redhat.com>
Gerrit-Reviewer: Shahar Havivi <shav...@redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to