Vered Volansky has posted comments on this change.

Change subject: core: Enhance RO need to update check
......................................................................


Patch Set 3:

(1 comment)

http://gerrit.ovirt.org/#/c/35456/3/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/UpdateVmDiskCommand.java
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/UpdateVmDiskCommand.java:

Line 593:     }
Line 594: 
Line 595:     protected boolean updateReadOnlyRequested() {
Line 596:         Boolean readOnlyNewValue = getNewDisk().getReadOnly();
Line 597:         return readOnlyNewValue != null && 
!vmDeviceForVm.getIsReadOnly().equals(readOnlyNewValue);
> Why do we need the "!= condition"?
Because null is not false. A test failed on this, so could actual code.
The original settings could be null for both, yet these options will show 
they're not equal. You rely on the value to be false if it's null in one 
occasion an not in the other.
Line 598:     }
Line 599: 
Line 600:     protected boolean isAtLeastOneVmIsNotDown(List<VM> 
vmsDiskPluggedTo) {
Line 601:         for (VM vm : vmsDiskPluggedTo) {


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I9bbfc60c3e9bda0133eec9b1db116f8e7bad9d1d
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Vered Volansky <vvola...@redhat.com>
Gerrit-Reviewer: Allon Mureinik <amure...@redhat.com>
Gerrit-Reviewer: Tal Nisan <tni...@redhat.com>
Gerrit-Reviewer: Vered Volansky <vvola...@redhat.com>
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to