Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcvs2001-06-08 09:04:34 -0400
committercvs2001-06-08 09:04:34 -0400
commit66e9ddfbe5dea54e176e71854a02a9dfe50200b2 (patch)
tree4cb0018a40b67d82c86d50211d3671a047b7177f /bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer
parentc52c3c06707d09034b054ba82f32c69ad76ec58f (diff)
downloadeclipse.platform.team-66e9ddfbe5dea54e176e71854a02a9dfe50200b2.tar.gz
eclipse.platform.team-66e9ddfbe5dea54e176e71854a02a9dfe50200b2.tar.xz
eclipse.platform.team-66e9ddfbe5dea54e176e71854a02a9dfe50200b2.zip
1GEYE24: ITPVCM:ALL - .vcm_meta is staying open
Diffstat (limited to 'bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer')
-rw-r--r--bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/Differencer.java22
1 files changed, 13 insertions, 9 deletions
diff --git a/bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/Differencer.java b/bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/Differencer.java
index 20c023851..ac912f021 100644
--- a/bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/Differencer.java
+++ b/bundles/org.eclipse.compare/compare/org/eclipse/compare/structuremergeviewer/Differencer.java
@@ -426,11 +426,11 @@ public class Differencer {
if (is1 == null && is2 == null) // no byte contents
return true;
-
- if (is1 == null || is2 == null) // only one has contents
- return false;
try {
+ if (is1 == null || is2 == null) // only one has contents
+ return false;
+
while (true) {
int c1= is1.read();
int c2= is2.read();
@@ -442,13 +442,17 @@ public class Differencer {
}
} catch (IOException ex) {
} finally {
- try {
- is1.close();
- } catch(IOException ex) {
+ if (is1 != null) {
+ try {
+ is1.close();
+ } catch(IOException ex) {
+ }
}
- try {
- is2.close();
- } catch(IOException ex) {
+ if (is2 != null) {
+ try {
+ is2.close();
+ } catch(IOException ex) {
+ }
}
}
return false;

Back to the top