diff options
Diffstat (limited to 'plugins/org.eclipse.emf.edapt.common/src/org/eclipse/emf/edapt/common/LoggingUtils.java')
-rw-r--r-- | plugins/org.eclipse.emf.edapt.common/src/org/eclipse/emf/edapt/common/LoggingUtils.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/plugins/org.eclipse.emf.edapt.common/src/org/eclipse/emf/edapt/common/LoggingUtils.java b/plugins/org.eclipse.emf.edapt.common/src/org/eclipse/emf/edapt/common/LoggingUtils.java index df93560..4d5d97a 100644 --- a/plugins/org.eclipse.emf.edapt.common/src/org/eclipse/emf/edapt/common/LoggingUtils.java +++ b/plugins/org.eclipse.emf.edapt.common/src/org/eclipse/emf/edapt/common/LoggingUtils.java @@ -59,12 +59,18 @@ public final class LoggingUtils { /** Log status. */ public static void log(Plugin plugin, IStatus status) { + if (plugin == null) { + return; + } plugin.getLog().log(status); } /** Create status. */ public static IStatus createStatus(Plugin plugin, int severity, int code, String message, Throwable exception) { + if (plugin == null) { + return null; + } String pluginId = plugin.getBundle().getSymbolicName(); return new Status(severity, pluginId, code, message, exception); } |