We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In https://github.com/eclipse-sirius/sirius-emf-json/blob/master/bundles/org.eclipse.sirius.emfjson/src/main/java/org/eclipse/sirius/emfjson/utils/GsonEObjectDeserializer.java#L619, this.resourceSet.getPackageRegistry() is called without check on this.resourceSet, which can raise NPE. Furthermore, in https://github.com/eclipse-sirius/sirius-emf-json/blob/master/bundles/org.eclipse.sirius.emfjson/src/main/java/org/eclipse/sirius/emfjson/utils/GsonEObjectDeserializer.java#L174, a variable this.packageRegistry already contains the appropriate value.
this.resourceSet.getPackageRegistry()
this.resourceSet
this.packageRegistry
So, it seems that this.resourceSet.getPackageRegistry() should be replaced by this.packageRegistry in GsonEObjectDeserializer
GsonEObjectDeserializer
The text was updated successfully, but these errors were encountered:
[50] Fix potential NPE in GsonEObjectDeserializer#resolveType
524160c
Bug: #50 Signed-off-by: Axel RICHARD <[email protected]>
AxelRICHARD
Successfully merging a pull request may close this issue.
In https://github.com/eclipse-sirius/sirius-emf-json/blob/master/bundles/org.eclipse.sirius.emfjson/src/main/java/org/eclipse/sirius/emfjson/utils/GsonEObjectDeserializer.java#L619,
this.resourceSet.getPackageRegistry()
is called without check onthis.resourceSet
, which can raise NPE.Furthermore, in https://github.com/eclipse-sirius/sirius-emf-json/blob/master/bundles/org.eclipse.sirius.emfjson/src/main/java/org/eclipse/sirius/emfjson/utils/GsonEObjectDeserializer.java#L174, a variable
this.packageRegistry
already contains the appropriate value.So, it seems that
this.resourceSet.getPackageRegistry()
should be replaced bythis.packageRegistry
inGsonEObjectDeserializer
The text was updated successfully, but these errors were encountered: