Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Watson2010-04-02 18:13:04 +0000
committerThomas Watson2010-04-02 18:13:04 +0000
commit1fe347c28b9a502fc86d64cb59e0de92b465799e (patch)
tree35ca4e9f746806609122fd2f5efa0831611905ea
parent0600072aabc6267c58631637ac8efb9585cb1971 (diff)
downloadrt.equinox.framework-1fe347c28b9a502fc86d64cb59e0de92b465799e.tar.gz
rt.equinox.framework-1fe347c28b9a502fc86d64cb59e0de92b465799e.tar.xz
rt.equinox.framework-1fe347c28b9a502fc86d64cb59e0de92b465799e.zip
back out - Bug 300820 - Failure in testBug289719 on I20100125-0800 build
-rw-r--r--bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/StartLevelManager.java9
1 files changed, 3 insertions, 6 deletions
diff --git a/bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/StartLevelManager.java b/bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/StartLevelManager.java
index 64425f045..5ecc3e39a 100644
--- a/bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/StartLevelManager.java
+++ b/bundles/org.eclipse.osgi/core/framework/org/eclipse/osgi/framework/internal/core/StartLevelManager.java
@@ -356,7 +356,7 @@ public class StartLevelManager implements EventDispatcher, EventListener, StartL
* <tt>AdminPermission</tt> and the Java runtime environment supports
* permissions.
*/
- public void setBundleStartLevel(Bundle bundle, int newSL) {
+ public void setBundleStartLevel(org.osgi.framework.Bundle bundle, int newSL) {
String exceptionText = null;
if (bundle.getBundleId() == 0) { // system bundle has id=0
@@ -372,8 +372,7 @@ public class StartLevelManager implements EventDispatcher, EventListener, StartL
framework.checkAdminPermission(bundle, AdminPermission.EXECUTE);
try {
// if the bundle's startlevel is not already at the requested startlevel
- int oldSL = ((AbstractBundle) bundle).getStartLevel();
- if (newSL != oldSL) {
+ if (newSL != ((org.eclipse.osgi.framework.internal.core.AbstractBundle) bundle).getStartLevel()) {
final AbstractBundle b = (AbstractBundle) bundle;
b.getBundleData().setStartLevel(newSL);
try {
@@ -390,9 +389,7 @@ public class StartLevelManager implements EventDispatcher, EventListener, StartL
throw (RuntimeException) e.getException();
}
// handle starting or stopping the bundle asynchronously
- if (newSL > oldSL || !((AbstractBundle) bundle).isActive())
- // only need to do this if the newSL > oldSL (stopping) or the bundle is not active (could activate)
- issueEvent(new StartLevelEvent(StartLevelEvent.CHANGE_BUNDLE_SL, newSL, (AbstractBundle) bundle));
+ issueEvent(new StartLevelEvent(StartLevelEvent.CHANGE_BUNDLE_SL, newSL, (AbstractBundle) bundle));
}
} catch (IOException e) {
framework.publishFrameworkEvent(FrameworkEvent.ERROR, bundle, e);

Back to the top