Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristopher Frost2011-05-18 13:09:19 -0400
committerChristopher Frost2011-05-18 13:09:19 -0400
commite44fa636541db42c095b9fbbbae18d0e68a8a841 (patch)
tree426b66dde203627b57720ba53efa06f9f52a23a4
parent83848c5cbcaadc649158c4be03b04b4b138a9e06 (diff)
downloadorg.eclipse.virgo.kernel-e44fa636541db42c095b9fbbbae18d0e68a8a841.tar.gz
org.eclipse.virgo.kernel-e44fa636541db42c095b9fbbbae18d0e68a8a841.tar.xz
org.eclipse.virgo.kernel-e44fa636541db42c095b9fbbbae18d0e68a8a841.zip
Aditional Null check required when looking in the service reg
-rw-r--r--org.eclipse.virgo.kernel.model/src/main/java/org/eclipse/virgo/kernel/model/internal/StandardSpringContextAccessor.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/org.eclipse.virgo.kernel.model/src/main/java/org/eclipse/virgo/kernel/model/internal/StandardSpringContextAccessor.java b/org.eclipse.virgo.kernel.model/src/main/java/org/eclipse/virgo/kernel/model/internal/StandardSpringContextAccessor.java
index 380a2f9d..26794367 100644
--- a/org.eclipse.virgo.kernel.model/src/main/java/org/eclipse/virgo/kernel/model/internal/StandardSpringContextAccessor.java
+++ b/org.eclipse.virgo.kernel.model/src/main/java/org/eclipse/virgo/kernel/model/internal/StandardSpringContextAccessor.java
@@ -41,7 +41,7 @@ public class StandardSpringContextAccessor implements SpringContextAccessor {
String symbolicName = bundle.getSymbolicName();
try {
ServiceReference<?>[] refs = bundleContext.getAllServiceReferences(APPLICATION_CONTEXT_CLASS_NAME, "(Bundle-SymbolicName=" + symbolicName + ")");
- if (refs.length > 0) {
+ if (refs != null && refs.length > 0) {
return true;
}
} catch (InvalidSyntaxException e) {

Back to the top