diff options
author | Michael Valenta | 2003-06-17 20:04:57 +0000 |
---|---|---|
committer | Michael Valenta | 2003-06-17 20:04:57 +0000 |
commit | 20f3ff5992c9e9693c5bd68a373e6ace62c36c1e (patch) | |
tree | 26b3c92120b092022cd7341beec48e4907b16cd6 | |
parent | 1990b0d9ce3b07be5363ad35900984d95c617f1b (diff) | |
download | eclipse.platform.team-20f3ff5992c9e9693c5bd68a373e6ace62c36c1e.tar.gz eclipse.platform.team-20f3ff5992c9e9693c5bd68a373e6ace62c36c1e.tar.xz eclipse.platform.team-20f3ff5992c9e9693c5bd68a373e6ace62c36c1e.zip |
30502: [CVS Core UI] Stacktrace lost when status logged
2 files changed, 14 insertions, 4 deletions
diff --git a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSMergeSubscriber.java b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSMergeSubscriber.java index a607661e0..c88e11192 100644 --- a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSMergeSubscriber.java +++ b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSMergeSubscriber.java @@ -175,7 +175,7 @@ public class CVSMergeSubscriber extends CVSSyncTreeSubscriber { resources.add(resource); } else { // log that a resource previously in the merge set is no longer in the workspace - CVSProviderPlugin.log(new CVSStatus(CVSStatus.INFO, "ignoring root resource not found in current workspace")); + CVSProviderPlugin.log(CVSStatus.INFO, "ignoring root resource not found in current workspace", null); } } if(resources.isEmpty()) { diff --git a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSProviderPlugin.java b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSProviderPlugin.java index 06e9601f1..834fe5fa6 100644 --- a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSProviderPlugin.java +++ b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSProviderPlugin.java @@ -154,13 +154,23 @@ public class CVSProviderPlugin extends Plugin { } /** - * Convenience method for logging CVSExceptiuons to the plugin log + * Convenience method for logging CoreExceptions to the plugin log */ public static void log(CoreException e) { - // For now, we'll log the status. However we should do more - log(e.getStatus()); + log(e.getStatus().getSeverity(), e.getMessage(), e); } + /** + * Log the given exception alloing with the provided message and severity indicator + */ + public static void log(int severity, String message, Throwable e) { + log(new Status(severity, ID, 0, message, e)); + } + + /** + * Log the given status. Do not use this method for the IStatus from a CoreException. + * Use<code>log(CoreException)</code> instead so the stack trace is not lost. + */ public static void log(IStatus status) { // For now, we'll log the status. However we should do more getPlugin().getLog().log(status); |