I noticed that diffstat(1) needlessly crashes when the input of an "Only in " line includes a UTF-8 character. It turned out that this problem is caused by the "len" argument passed to mbsrtowcs() being wrong. ---------- $ echo 'Only in .: A' | diffstat *** buffer overflow detected ***: terminated Aborted (core dumped) ---------- Reproducible: Always Additional Information: Since I couldn't find whom to report this problem from https://invisible-island.net/diffstat , I report here.
The actual data might be helpful (one of my test-scripts exercises that code, but data differs). I see the problem you're referring to, but in a quick check (Debian 12), I get no dump. Bugzilla works, but actually bugs works better, because it's mail-based, and I'm more likely to have the complete bug report and responses in my mail archive. ymmv.
fwiw, I can reproduce the problem with my Fedora42 machine.
This problem can be reproduced only when compiled with -D_FORTIFY_SOURCE=3 option. Fedora 38+ ( https://fedoraproject.org/wiki/Changes/Add_FORTIFY_SOURCE%3D3_to_distribution_build_flags ) and Ubuntu 24.04+ uses _FORTIFY_SOURCE=3. Presumably Debian 12 is using _FORTIFY_SOURCE=2.
Perhaps the detail we're discussing is also tied to the version of gcc (or libc6), since I see that I've logs from Fedora41 with FORTIFY_SOURCE=3, or something triggered by a single UTF-8 character (though that seems odd, since the mismatch would be greater for multiple characters).
Please see https://sourceware.org/bugzilla/show_bug.cgi?id=32899 for details.
This message is a reminder that Fedora Linux 42 is nearing its end of life. Fedora will stop maintaining and issuing updates for Fedora Linux 42 on 2026-05-13. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a 'version' of '42'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, change the 'version' to a later Fedora Linux version. Note that the version field may be hidden. Click the "Show advanced fields" button if you do not see it. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora Linux 42 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora Linux, you are encouraged to change the 'version' to a later version prior to this bug being closed.
This was fixed in diffstat 1.68, which is in Fedora 43