HDFS-17035. FsVolumeImpl#getActualNonDfsUsed may return negative value. (#5708). Contributed by farmmamba.
Reviewed-by: Shuyan Zhang <zqingchai@gmail.com> Reviewed-by: He Xiaoqiao <hexiaoqiao@apache.org> Signed-off-by: Ayush Saxena <ayushsaxena@apache.org>
This commit is contained in:
parent
0c209961f8
commit
ddae78b0ec
|
@ -499,7 +499,7 @@ public class FsVolumeImpl implements FsVolumeSpi {
|
|||
return used;
|
||||
}
|
||||
}
|
||||
return getDfUsed() - getDfsUsed();
|
||||
return Math.max(getDfUsed() - getDfsUsed(), 0L);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue