diff --git a/org.eclipse.jgit.iplog/src/org/eclipse/jgit/iplog/IpLogGenerator.java b/org.eclipse.jgit.iplog/src/org/eclipse/jgit/iplog/IpLogGenerator.java
index 1f60ee5628366194740c5f8c07679a51cb3ade63..040887ece4aafbeef7b76d941090214aee38fde4 100644
--- a/org.eclipse.jgit.iplog/src/org/eclipse/jgit/iplog/IpLogGenerator.java
+++ b/org.eclipse.jgit.iplog/src/org/eclipse/jgit/iplog/IpLogGenerator.java
@@ -389,7 +389,7 @@ private void scanProjectCommits(RevCommit start) throws IOException {
 					if (tw.getFileMode(0).getObjectType() == Constants.OBJ_BLOB) {
 						byte[] buf = openBlob(0);
 						for (int ptr = 0; ptr < buf.length;) {
-							ptr += RawParseUtils.nextLF(buf, ptr);
+							ptr = RawParseUtils.nextLF(buf, ptr);
 							addedLines++;
 						}
 					}