Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorslewis2007-04-20 22:29:59 +0000
committerslewis2007-04-20 22:29:59 +0000
commitc69a60549c7bfaf1443a6cc94b7a27ee2dbcd108 (patch)
tree95c45d50370384d319bd8a2e0da3c55262bf7685
parent215340edf887a4392a6c1dec2468b768a596d194 (diff)
downloadorg.eclipse.ecf-c69a60549c7bfaf1443a6cc94b7a27ee2dbcd108.tar.gz
org.eclipse.ecf-c69a60549c7bfaf1443a6cc94b7a27ee2dbcd108.tar.xz
org.eclipse.ecf-c69a60549c7bfaf1443a6cc94b7a27ee2dbcd108.zip
Changes to have all activator classes return non-null with calls to getDefault(), even in non-OSGi environments
-rw-r--r--providers/bundles/org.eclipse.ecf.provider.remoteservice/src/org/eclipse/ecf/internal/provider/remoteservice/Activator.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/providers/bundles/org.eclipse.ecf.provider.remoteservice/src/org/eclipse/ecf/internal/provider/remoteservice/Activator.java b/providers/bundles/org.eclipse.ecf.provider.remoteservice/src/org/eclipse/ecf/internal/provider/remoteservice/Activator.java
index 924576364..c3431396c 100644
--- a/providers/bundles/org.eclipse.ecf.provider.remoteservice/src/org/eclipse/ecf/internal/provider/remoteservice/Activator.java
+++ b/providers/bundles/org.eclipse.ecf.provider.remoteservice/src/org/eclipse/ecf/internal/provider/remoteservice/Activator.java
@@ -41,7 +41,10 @@ public class Activator implements BundleActivator {
*
* @return the shared instance
*/
- public static Activator getDefault() {
+ public synchronized static Activator getDefault() {
+ if (plugin == null) {
+ plugin = new Activator();
+ }
return plugin;
}

Back to the top