mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
Fix byte speed rates not being properly "humanized".
This commit is contained in:
@@ -898,7 +898,7 @@ partial class Dump
|
||||
minSpeed = currentSpeed;
|
||||
|
||||
PulseProgress?.Invoke(string.Format(Localization.Core.Reading_block_0_1, currentBlock,
|
||||
ByteSize.FromBytes(currentSpeed).Per(_oneSecond)));
|
||||
ByteSize.FromBytes(currentSpeed).Per(_oneSecond).Humanize()));
|
||||
|
||||
sense = _dev.Read6(out cmdBuf, out senseBuf, false, fixedLen, transferLen, blockSize, _dev.Timeout,
|
||||
out duration);
|
||||
@@ -1393,7 +1393,8 @@ partial class Dump
|
||||
(end - chkStart).Humanize(minUnit: TimeUnit.Second));
|
||||
|
||||
_dumpLog.WriteLine(Localization.Core.Average_checksum_speed_0,
|
||||
ByteSize.FromBytes(blockSize * (blocks + 1)).Per(totalChkDuration.Milliseconds()));
|
||||
ByteSize.FromBytes(blockSize * (blocks + 1)).Per(totalChkDuration.Milliseconds()).
|
||||
Humanize());
|
||||
|
||||
if(_preSidecar != null)
|
||||
{
|
||||
@@ -1478,14 +1479,15 @@ partial class Dump
|
||||
|
||||
UpdateStatus?.Invoke(string.Format(Localization.Core.Average_speed_0,
|
||||
ByteSize.FromBytes(blockSize * (blocks + 1)).
|
||||
Per(totalDuration.Milliseconds())));
|
||||
Per(totalDuration.Milliseconds()).Humanize()));
|
||||
|
||||
if(maxSpeed > 0)
|
||||
UpdateStatus?.Invoke(string.Format(Localization.Core.Fastest_speed_burst_0, ByteSize.FromMegabytes(maxSpeed).Per(_oneSecond)));
|
||||
UpdateStatus?.Invoke(string.Format(Localization.Core.Fastest_speed_burst_0,
|
||||
ByteSize.FromMegabytes(maxSpeed).Per(_oneSecond).Humanize()));
|
||||
|
||||
if(minSpeed is > 0 and < double.MaxValue)
|
||||
UpdateStatus?.Invoke(string.Format(Localization.Core.Slowest_speed_burst_0,
|
||||
ByteSize.FromMegabytes(minSpeed).Per(_oneSecond)));
|
||||
ByteSize.FromMegabytes(minSpeed).Per(_oneSecond).Humanize()));
|
||||
|
||||
UpdateStatus?.Invoke(string.Format(Localization.Core._0_sectors_could_not_be_read, _resume.BadBlocks.Count));
|
||||
UpdateStatus?.Invoke("");
|
||||
|
||||
Reference in New Issue
Block a user