HDFS-13663. Should throw exception when incorrect block size is set. Contributed by Shweta.
This commit is contained in:
parent
1bc106a738
commit
87eeb26e72
@ -275,7 +275,9 @@ void syncBlock(List<BlockRecord> syncList) throws IOException {
|
||||
}
|
||||
// recover() guarantees syncList will have at least one replica with RWR
|
||||
// or better state.
|
||||
assert minLength != Long.MAX_VALUE : "wrong minLength";
|
||||
if (minLength == Long.MAX_VALUE) {
|
||||
throw new IOException("Incorrect block size");
|
||||
}
|
||||
newBlock.setNumBytes(minLength);
|
||||
break;
|
||||
case RUR:
|
||||
|
Loading…
Reference in New Issue
Block a user