You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@aries.apache.org by no...@apache.org on 2010/02/19 15:04:26 UTC
svn commit: r911814 -
/incubator/aries/trunk/jmx/jmx-core/src/main/java/org/apache/aries/jmx/framework/BundleState.java
Author: not
Date: Fri Feb 19 14:04:26 2010
New Revision: 911814
URL: http://svn.apache.org/viewvc?rev=911814&view=rev
Log:
ARIES-193 Protect against getBundles() returning null.
Modified:
incubator/aries/trunk/jmx/jmx-core/src/main/java/org/apache/aries/jmx/framework/BundleState.java
Modified: incubator/aries/trunk/jmx/jmx-core/src/main/java/org/apache/aries/jmx/framework/BundleState.java
URL: http://svn.apache.org/viewvc/incubator/aries/trunk/jmx/jmx-core/src/main/java/org/apache/aries/jmx/framework/BundleState.java?rev=911814&r1=911813&r2=911814&view=diff
==============================================================================
--- incubator/aries/trunk/jmx/jmx-core/src/main/java/org/apache/aries/jmx/framework/BundleState.java (original)
+++ incubator/aries/trunk/jmx/jmx-core/src/main/java/org/apache/aries/jmx/framework/BundleState.java Fri Feb 19 14:04:26 2010
@@ -262,8 +262,10 @@
public TabularData listBundles() throws IOException {
Bundle[] containerBundles = bundleContext.getBundles();
List<BundleData> bundleDatas = new ArrayList<BundleData>();
- for (Bundle containerBundle : containerBundles) {
- bundleDatas.add(new BundleData(bundleContext, containerBundle, packageAdmin, startLevel));
+ if (containerBundles != null) {
+ for (Bundle containerBundle : containerBundles) {
+ bundleDatas.add(new BundleData(bundleContext, containerBundle, packageAdmin, startLevel));
+ }
}
TabularData bundleTable = new TabularDataSupport(BUNDLES_TYPE);
for (BundleData bundleData : bundleDatas) {