[
https://issues.apache.org/jira/browse/FELIX-1829?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13412511#comment-13412511
]
Christian Vogel commented on FELIX-1829:
----------------------------------------
In OSGi each bundle MUST have a symbolic name, because its the unique
identifier. So maybe it would be better to throw a
`NoSymbolicNameProvidedException` or something else to prevent having bundles
withoutthe identifier.
> Method AbstractDeploymentPackage.getBundle(...) throws NullPointerException
> ---------------------------------------------------------------------------
>
> Key: FELIX-1829
> URL: https://issues.apache.org/jira/browse/FELIX-1829
> Project: Felix
> Issue Type: Bug
> Components: Deployment Admin
> Reporter: Pavel Kodl
> Assignee: Marcel Offermans
> Priority: Critical
>
> Because in this method on row 115 is:
> if (bundles[i].getSymbolicName().equals(symbolicName)) {
> but should be something like:
> String sn = bundles[i].getSymbolicName();
> if (sn != null && sn.equals(symbolicName)) {
> It happends by installing a deployment package, stack trace is:
> java.lang.NullPointerException
> at
> org.apache.felix.deploymentadmin.AbstractDeploymentPackage.getBundle(AbstractDeploymentPackage.java:115)
> at
> org.apache.felix.deploymentadmin.spi.UpdateCommand.execute(UpdateCommand.java:70)
> at
> org.apache.felix.deploymentadmin.spi.DeploymentSessionImpl.call(DeploymentSessionImpl.java:74)
> at
> org.apache.felix.deploymentadmin.DeploymentAdminImpl.installDeploymentPackage(DeploymentAdminImpl.java:215)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira