sort: don’t trust st_size on /proc files
commit8ff3903281e03d36dd1aa2a202a56f38af726d91
authorPaul Eggert <eggert@cs.ucla.edu>
Sat, 6 Apr 2024 22:17:14 +0000 (6 15:17 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Sat, 6 Apr 2024 22:18:28 +0000 (6 15:18 -0700)
tree5947dfeb748a0e53cc16f62510a4a6821de80999
parentac6b8d8224de140f5a6f2ca66e6ce279604a37e6
sort: don’t trust st_size on /proc files

Problem and fix reported by Takashi Kusumi in:
https://bugs.gnu.org/70231
* src/sort.c (sort_buffer_size): Don’t trust st_size == 0.
src/sort.c