Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Fluegge2010-07-07 10:46:03 -0400
committerMartin Fluegge2010-07-07 10:46:03 -0400
commite226589b37d964e9d58de60b4ecdc8a66f52a96f (patch)
treee696b184d7ac59bc59e3f6032ec5be18db07b7ee /plugins
parente77d6e617f9cb81e052d7e605d354788bf545155 (diff)
downloadcdo-e226589b37d964e9d58de60b4ecdc8a66f52a96f.tar.gz
cdo-e226589b37d964e9d58de60b4ecdc8a66f52a96f.tar.xz
cdo-e226589b37d964e9d58de60b4ecdc8a66f52a96f.zip
[319132] NPE when using Legacy mode.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=319132
Diffstat (limited to 'plugins')
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java19
1 files changed, 11 insertions, 8 deletions
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java
index 6254754a95..bac6e0e5ae 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java
@@ -1006,17 +1006,20 @@ public abstract class CDOLegacyWrapper extends CDOObjectWrapper
if (cdoObject != null && !FSMUtil.isTransient(cdoObject))
{
EStore eStore = cdoObject.eStore();
- if (feature.isMany())
+ if (eStore != null)
{
- int index = eStore.indexOf(cdoObject, feature, instance.cdoID());
- if (index != EStore.NO_INDEX)
+ if (feature.isMany())
{
- eStore.set(cdoObject, feature, index, instance);
+ int index = eStore.indexOf(cdoObject, feature, instance.cdoID());
+ if (index != EStore.NO_INDEX)
+ {
+ eStore.set(cdoObject, feature, index, instance);
+ }
+ }
+ else
+ {
+ eStore.set(cdoObject, feature, 0, instance);
}
- }
- else
- {
- eStore.set(cdoObject, feature, 0, instance);
}
}
else

Back to the top