From 7a0cdacb6e10fc2418f0281fa96a422ef4c15113 Mon Sep 17 00:00:00 2001 From: Michael McCandless Date: Tue, 7 Aug 2012 11:45:54 +0000 Subject: [PATCH] LUCENE-3892: fix incorrect numBits computation git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/branches/pforcodec_3892@1370194 13f79535-47bb-0310-9956-ffa450edef68 --- .../core/src/java/org/apache/lucene/codecs/block/ForUtil.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lucene/core/src/java/org/apache/lucene/codecs/block/ForUtil.java b/lucene/core/src/java/org/apache/lucene/codecs/block/ForUtil.java index 3df39d7335d..4d63ca256ff 100644 --- a/lucene/core/src/java/org/apache/lucene/codecs/block/ForUtil.java +++ b/lucene/core/src/java/org/apache/lucene/codecs/block/ForUtil.java @@ -74,9 +74,7 @@ public final class ForUtil { // nocommit assert header isn't "malformed", ie besides // numBytes / bit-width there is nothing else! - int numBits = ((header >> 8) & MASK[6]); - - decompressCore(intBuffer, data, numBits); + decompressCore(intBuffer, data, getNumBits(header)); } static void decompressCore(IntBuffer intBuffer, int[] data, int numBits) {