Hello Shmuel Melamud,
I'd like you to do a code review. Please visit
https://gerrit.ovirt.org/40918
to review the following change.
Change subject: core: null field value in getVmDeviceFieldsToUpdateOnNextRun()
......................................................................
core: null field value in getVmDeviceFieldsToUpdateOnNextRun()
Handle null field value in getVmDeviceFieldsToUpdateOnNextRun(). In this
case, current device configuration is preserved.
Change-Id: I6164151c38a36c32351e32c91e78b092bc1fe013
Signed-off-by: Shmuel Melamud <[email protected]>
---
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VmHandler.java
1 file changed, 3 insertions(+), 1 deletion(-)
git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/18/40918/1
diff --git
a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VmHandler.java
b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VmHandler.java
index a748331..9e29d58 100644
---
a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VmHandler.java
+++
b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/VmHandler.java
@@ -848,7 +848,9 @@
try {
Object value = field.get(objectWithEditableDeviceFields);
- if (value instanceof Boolean) {
+ if (value == null) {
+ // preserve current configuration
+ } else if (value instanceof Boolean) {
addDeviceUpdateOnNextRun(vmId, annotation, null, value,
fieldList);
} else if (value instanceof Map) {
Map<?, ?> map = (Map<?, ?>) value;
--
To view, visit https://gerrit.ovirt.org/40918
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I6164151c38a36c32351e32c91e78b092bc1fe013
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Shmuel Leib Melamud <[email protected]>
Gerrit-Reviewer: Shmuel Melamud <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches