Package: mtools Version: 4.0.33-1+really4.0.32-1 Severity: normal Tags: upstream patch
The overall byte count shown in the summary is truncated (from the left) to ten effective digits, and is therefore wrong as soon as it reaches 10 GB (10^10 B): $ mdir f:abc Volume in drive F has no label Volume Serial Number is 1234-5678 Directory for F:/abc . <DIR> 2024-05-21 13:32 .. <DIR> 2024-05-21 13:32 f1 3000000000 2024-05-21 13:32 f2 3000000000 2024-05-21 13:32 f3 3000000000 2024-05-21 13:32 f4 3000000000 2024-05-21 13:32 6 files 2 000 000 000 bytes ** should be 12 000 000 000 ** 17 331 192 064 bytes free I haven't the time to modify dotted_num() to prevent omission of the most significant digits, but the following patch is a quick fix for sizes up to 10 TB - 1. Best regards, g.b. --- mdir.c.old 2021-07-15 14:28:53.000000000 +0200 +++ mdir.c 2024-05-21 13:18:25.079157668 +0200 @@ -229,8 +229,8 @@ putchar(' '); else putchar('s'); - printf(" %s bytes\n", - dotted_num(bytes, 13, &s1)); + printf(" %s bytes\n", + dotted_num(bytes, 17, &s1)); if(s1) free(s1); } -- System Information: Debian Release: 12.5 APT prefers stable-updates APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 6.1.0-21-amd64 (SMP w/12 CPU threads; PREEMPT) Locale: LANG=C, LC_CTYPE=C.UTF-8 (charmap=UTF-8), LANGUAGE not set Shell: /bin/sh linked to /usr/bin/dash Versions of packages mtools depends on: ii libc6 2.36-9+deb12u7 mtools recommends no packages. Versions of packages mtools suggests: pn floppyd <none> -- no debconf information