Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorslewis2007-04-20 18:29:35 -0400
committerslewis2007-04-20 18:29:35 -0400
commita866e7950a27f8a12af082b0bbcfc8fdf9df77a8 (patch)
tree295bbaec4db347ce099d78f02da16a1cd5a18507 /framework/bundles/org.eclipse.ecf.presence
parentfbdb1efaf220a6859ae4f350f892a4b93ba0d71c (diff)
downloadorg.eclipse.ecf-a866e7950a27f8a12af082b0bbcfc8fdf9df77a8.tar.gz
org.eclipse.ecf-a866e7950a27f8a12af082b0bbcfc8fdf9df77a8.tar.xz
org.eclipse.ecf-a866e7950a27f8a12af082b0bbcfc8fdf9df77a8.zip
Changes to have all activator classes return non-null with calls to getDefault(), even in non-OSGi environments
Diffstat (limited to 'framework/bundles/org.eclipse.ecf.presence')
-rw-r--r--framework/bundles/org.eclipse.ecf.presence/src/org/eclipse/ecf/internal/presence/PresencePlugin.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/framework/bundles/org.eclipse.ecf.presence/src/org/eclipse/ecf/internal/presence/PresencePlugin.java b/framework/bundles/org.eclipse.ecf.presence/src/org/eclipse/ecf/internal/presence/PresencePlugin.java
index 4d9d087a1..43e496efc 100644
--- a/framework/bundles/org.eclipse.ecf.presence/src/org/eclipse/ecf/internal/presence/PresencePlugin.java
+++ b/framework/bundles/org.eclipse.ecf.presence/src/org/eclipse/ecf/internal/presence/PresencePlugin.java
@@ -76,7 +76,10 @@ public class PresencePlugin implements BundleActivator {
/**
* Returns the shared instance.
*/
- public static PresencePlugin getDefault() {
+ public synchronized static PresencePlugin getDefault() {
+ if (plugin == null) {
+ plugin = new PresencePlugin();
+ }
return plugin;
}

Back to the top