diff src/org/tmatesoft/hg/repo/HgDataFile.java @ 158:b413b16d10a5

Integer offsets and file length explictly, rather than casts throughout code. Inflater may benefit from total length hint, but shall calculate it by its own if needed
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Wed, 09 Mar 2011 13:16:37 +0100
parents d5268ca7715b
children a5198b6487dc
line wrap: on
line diff
--- a/src/org/tmatesoft/hg/repo/HgDataFile.java	Wed Mar 09 05:22:17 2011 +0100
+++ b/src/org/tmatesoft/hg/repo/HgDataFile.java	Wed Mar 09 13:16:37 2011 +0100
@@ -320,7 +320,7 @@
 
 		@Override
 		protected void prepare(int revisionNumber, DataAccess da) throws HgException, IOException {
-			long daLength = da.length();
+			final int daLength = da.length();
 			if (daLength < 4 || da.readByte() != 1 || da.readByte() != 10) {
 				metadata.recordNone(revisionNumber);
 				da.reset();