Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Valenta2003-10-14 14:20:14 +0000
committerMichael Valenta2003-10-14 14:20:14 +0000
commitbf51053495cc707efd9f6b781ee94265c1fcee83 (patch)
treeb003e319ed950a9f874b6b52e359d37849358085
parentda648dda55bba0232e642c843f08ffc66ee7e55d (diff)
downloadeclipse.platform.team-bf51053495cc707efd9f6b781ee94265c1fcee83.tar.gz
eclipse.platform.team-bf51053495cc707efd9f6b781ee94265c1fcee83.tar.xz
eclipse.platform.team-bf51053495cc707efd9f6b781ee94265c1fcee83.zip
4658: CVS connections left open
-rw-r--r--bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSTeamProvider.java15
1 files changed, 8 insertions, 7 deletions
diff --git a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSTeamProvider.java b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSTeamProvider.java
index 4bebfc688..3f83af788 100644
--- a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSTeamProvider.java
+++ b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/CVSTeamProvider.java
@@ -1360,13 +1360,13 @@ public class CVSTeamProvider extends RepositoryProvider {
monitor.beginTask(null, 100);
Session session = new Session(workspaceRoot.getRemoteLocation(), workspaceRoot.getLocalRoot(), true);
try {
- session.open(Policy.subMonitorFor(monitor, 10), true /* open for modification */);
- } catch (CVSException e1) {
- // If the connection cannot be opened, just exit normally.
- // The notifications will be sent when a connection can be made
- return;
- }
- try {
+ try {
+ session.open(Policy.subMonitorFor(monitor, 10), true /* open for modification */);
+ } catch (CVSException e1) {
+ // If the connection cannot be opened, just exit normally.
+ // The notifications will be sent when a connection can be made
+ return;
+ }
Command.NOOP.execute(
session,
Command.NO_GLOBAL_OPTIONS,
@@ -1377,6 +1377,7 @@ public class CVSTeamProvider extends RepositoryProvider {
} catch (CVSException e) {
exception[0] = e;
} finally {
+ session.close();
monitor.done();
}
}

Back to the top