int precision = (buffer[offset] & PRECISION_MASK) >> PRECISION_SHIFT;
if((size+offset) >= buffer.length) {
logger.error("Error extracting value - length={}, offset={}, size={}.",
new Object[] { buffer.length, offset, size});
throw new NumberFormatException();
}
int value = 0;
int i;
for (i = 0; i < size; ++i) {