Description of Problem: The block sizes reported by stat are obviously wrong. Version-Release number of selected component (if applicable): binand@binand[~/Stattest]:(82) rpm -q stat stat-2.5-5 How Reproducible: Always. Steps to Reproduce: 1. Run stat on anything. You get output like: binand@binand[~]:(12) stat ./.profile File: "./.profile" Size: 3317 Blocks: 8 IO Block: -4611700930553835520 Regular File [snip] Expected Results: The correct IO Block size (4096, I guess). Additional Information: A printf format string in stat.c is wrong, I think. statbuf.st_blksize is of type blksize_t' which is long int on my system, but the printf format used is %lld in stat.c. Changing it to %ld got me correct results. Incidentally, there are lots of anomalies in the printf format strings used in stat.c. When -t is given, for the block size, %llu is used, but otherwise, %lld is used. Please fix. I haven't done a full check on all the other format specifiers used, but the above two can be fixed using the attached patch.
Created attachment 74584 [details] patch to stat.c
3.3-1 or new in rawhide already fixed this bug. nevertheless, thanks for your patch.