Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 353217 - NPE during copy of references in EMFCompareEObjectCopier
Summary: NPE during copy of references in EMFCompareEObjectCopier
Status: CLOSED FIXED
Alias: None
Product: EMFCompare
Classification: Modeling
Component: Core (show other bugs)
Version: 1.3   Edit
Hardware: PC Windows 7
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: EMF Compare CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-27 10:54 EDT by Cedric Notot CLA
Modified: 2011-08-09 04:33 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Cedric Notot CLA 2011-07-27 10:54:48 EDT
Build Identifier: 20110615-0604

When an object which is not embedded in a resource is given to the findReferencedObjectCopy() method of EMFCompareEObjectCopier class, a NPE is thwrown.

Reproducible: Always

Steps to Reproduce:
1. Compare a model "M" which owns an object "A" which references an EPackage "B" of an ecore model.
2. Merge the object A in the model M' from M.
3. NPE will be thrown during the merge (copy) of the linked EPackage B because the eReference "eFactoryInstance" returns an EFactory which is not in a Resource.
Comment 1 Laurent Goubet CLA 2011-08-09 04:33:19 EDT
The match, diff and merge process have seen a great deal of improvement in the past week, with the addition of unit tests for most of the different use cases (one use case = one possible "diff" between models) we could think of.

The particular issue of NPEs when merging objects not contained in a resource (such as the factory instance this bug is about) is one of the things that has been tested and fixed.

These changes have been pushed on both master and the 1.2 maintenance stream. They are available in the builds
 - 1.2 integration : I201108090404
 - 1.3 integration : I201108090415