Description
INodeFile#diskspaceConsumed() checks the state of the file and use the full block size for the last block if it is under construction. This is incorrect, because a file can be under construction but the last block is already finalized. It should check the status of the last block instead.
This issue was fixed in 2.1.0 when the snapshot feature was merged. A subtask, HDFS-4503, consolidated several methods and as a result this bug disappeared.
A separate fix is needed for 0.23.