LUCENE-1007: woops ... Integer.SIZE is Java 1.5 only

git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@581355 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael McCandless 2007-10-02 19:21:28 +00:00
parent 54729a50b6
commit f3119614e6

View File

@ -2305,7 +2305,7 @@ final class DocumentsWriter {
bufferedDeleteTerms.put(term, new Num(docCount));
// This is coarse approximation of actual bytes used:
numBytesUsed += (term.field().length() + term.text().length()) * BYTES_PER_CHAR
+ Integer.SIZE/8 + 5 * OBJECT_HEADER_BYTES + 5 * OBJECT_POINTER_BYTES;
+ 4 + 5 * OBJECT_HEADER_BYTES + 5 * OBJECT_POINTER_BYTES;
if (ramBufferSize != IndexWriter.DISABLE_AUTO_FLUSH
&& numBytesUsed > ramBufferSize) {
bufferIsFull = true;