Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Valenta2003-09-15 09:40:28 -0400
committerMichael Valenta2003-09-15 09:40:28 -0400
commit9f834583a170676e9bb33fbc578fcfa7234279b0 (patch)
treede1fdeee797d979b3eb6b937c3aa315a15889ee2
parent254b70f97dca0ca4405081e1b779e8d363f4dd59 (diff)
downloadeclipse.platform.team-9f834583a170676e9bb33fbc578fcfa7234279b0.tar.gz
eclipse.platform.team-9f834583a170676e9bb33fbc578fcfa7234279b0.tar.xz
eclipse.platform.team-9f834583a170676e9bb33fbc578fcfa7234279b0.zip
Only print warning once per fileI20030916
-rw-r--r--bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/client/CRLFDetectInputStream.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/client/CRLFDetectInputStream.java b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/client/CRLFDetectInputStream.java
index a16860c4c..95f3f87a0 100644
--- a/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/client/CRLFDetectInputStream.java
+++ b/bundles/org.eclipse.team.cvs.core/src/org/eclipse/team/internal/ccvs/core/client/CRLFDetectInputStream.java
@@ -28,6 +28,7 @@ public class CRLFDetectInputStream extends FilterInputStream {
private boolean previousCR;
private String filename;
+ private boolean reported = false;
protected CRLFDetectInputStream(InputStream in, ICVSFile file) {
super(in);
@@ -86,8 +87,10 @@ public class CRLFDetectInputStream extends FilterInputStream {
* Test the byte to see if a CRLF sequence was read
*/
private void testForCRLF(byte next) {
+ if (reported) return;
if (previousCR && next == '\n') {
CVSProviderPlugin.log(IStatus.WARNING, Policy.bind("CRLFDetectInputStream.0", filename), null); //$NON-NLS-1$
+ reported = true;
}
previousCR = (next == '\r');
}

Back to the top