diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/merge/EolAwareOutputStream.java b/org.eclipse.jgit/src/org/eclipse/jgit/merge/EolAwareOutputStream.java index 3fd2374f3..1ddac18e5 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/merge/EolAwareOutputStream.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/merge/EolAwareOutputStream.java @@ -84,4 +84,12 @@ public void write(int val) throws IOException { out.write(val); bol = (val == '\n'); } + + @Override + public void write(byte[] buf, int pos, int cnt) throws IOException { + if (cnt > 0) { + out.write(buf, pos, cnt); + bol = (buf[pos + (cnt - 1)] == '\n'); + } + } }