Maor Lipchuk has posted comments on this change.
Change subject: core: Fix potential NPE when adding LUN disk
......................................................................
Patch Set 1: (1 inline comment)
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/AddDiskCommand.java
Line 84:
addCanDoActionMessage(VdcBllMessages.ACTION_TYPE_FAILED_VM_IMAGE_IS_LOCKED);
Line 85: } else {
Line 86: // if user sent drive check that its not in use
Line 87: returnValue = returnValue && (vm == null ||
isDiskCanBeAddedToVm(getParameters().getDiskInfo()));
Line 88: if (returnValue && DiskStorageType.IMAGE ==
getParameters().getDiskInfo().getDiskStorageType()) {
since the entire version check for DC is only relevant for IMAGEs, the check
can just be moved here, which should solve the LUN issue.
Line 89: returnValue = checkIfImageDiskCanBeAdded(vm);
Line 90: }
Line 91: if (returnValue && DiskStorageType.LUN ==
getParameters().getDiskInfo().getDiskStorageType()) {
Line 92: returnValue = checkIfLunDiskCanBeAdded();
--
To view, visit http://gerrit.ovirt.org/7362
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I6c55b95dac6f70435f7d1ac02a6a2a7cdd3f1e91
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Maor Lipchuk <[email protected]>
Gerrit-Reviewer: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Ayal Baron <[email protected]>
Gerrit-Reviewer: Daniel Erez <[email protected]>
Gerrit-Reviewer: Maor Lipchuk <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches