diff options
author | Michael Valenta | 2003-06-18 16:08:28 +0000 |
---|---|---|
committer | Michael Valenta | 2003-06-18 16:08:28 +0000 |
commit | 6dd7a81bc781a287d7ea9e50e57a6755153ff6cb (patch) | |
tree | 7d8775a6e147f2b002925ad28181e3dea307c747 | |
parent | e6dbde13281b75c3c608366d025dca3565063c81 (diff) | |
download | eclipse.platform.team-6dd7a81bc781a287d7ea9e50e57a6755153ff6cb.tar.gz eclipse.platform.team-6dd7a81bc781a287d7ea9e50e57a6755153ff6cb.tar.xz eclipse.platform.team-6dd7a81bc781a287d7ea9e50e57a6755153ff6cb.zip |
37292: [CVS Core] Unable to synchronize - Cannot close connection
2 files changed, 6 insertions, 4 deletions
diff --git a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSException.java b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSException.java index 1c1df398e..3aaf0a21f 100644 --- a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSException.java +++ b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSException.java @@ -36,7 +36,7 @@ public class CVSException extends TeamException { } public CVSException(int severity, int code, String message, Throwable e) { - super(new CVSStatus(severity, code, message, null)); + super(new CVSStatus(severity, code, message, e)); } public CVSException(int severity, int code, String message) { diff --git a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/connection/Connection.java b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/connection/Connection.java index 64eb74702..e99e4f12e 100644 --- a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/connection/Connection.java +++ b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/connection/Connection.java @@ -72,9 +72,11 @@ public class Connection { try { serverConnection.close(); } catch (IOException ex) { - // It is possible that the stream is being closed because of another exception. - // Therefore, the communication exception is logged instead of thrown - CVSProviderPlugin.log(new CVSCommunicationException(Policy.bind("Connection.cannotClose"), ex));//$NON-NLS-1$ + // Generally, errors on close are of no interest. + // However, log them if debugging is on + if (CVSProviderPlugin.getPlugin().isDebugging()) { + CVSProviderPlugin.log(new CVSCommunicationException(Policy.bind("Connection.cannotClose"), ex));//$NON-NLS-1$ + } } finally { fResponseStream = null; fIsEstablished = false; |