HADOOP-14616. Client fails to read a block with erasure code (XOR, native) when one of the data block is lost. Contributed by Huafeng Wang.

This commit is contained in:
Akira Ajisaka 2017-10-05 11:06:09 +09:00
parent cae1c734fe
commit fe84cdc9da
No known key found for this signature in database
GPG Key ID: C1EDBB9CA400FD50

View File

@ -58,7 +58,8 @@ Java_org_apache_hadoop_io_erasurecode_rawcoder_NativeXORRawDecoder_decodeImpl(
numParityUnits = ((IsalCoder*)xorDecoder)->numParityUnits;
chunkSize = (int)dataLen;
getInputs(env, inputs, inputOffsets, xorDecoder->inputs, numDataUnits);
getInputs(env, inputs, inputOffsets, xorDecoder->inputs,
numDataUnits + numParityUnits);
getOutputs(env, outputs, outputOffsets, xorDecoder->outputs, numParityUnits);
for (i = 0; i < numDataUnits + numParityUnits; i++) {