]> git.eshelyaron.com Git - emacs.git/commit
Improve inserted file coding system finding
authorPaul Eggert <eggert@cs.ucla.edu>
Sat, 12 Jul 2025 17:03:26 +0000 (10:03 -0700)
committerEshel Yaron <me@eshelyaron.com>
Thu, 24 Jul 2025 08:47:30 +0000 (10:47 +0200)
commite789d236a3fcc7c26c8c7c5376f5b7beb6fabcf7
treea052be5b462a91b1796d35b64fa8d1af15eb97db
parentc08a568715323a676f0f3557aff88cd3cc053b37
Improve inserted file coding system finding

* src/fileio.c (Finsert_file_contents): When inserting a file into
a nonempty buffer, improve the heuristic for determining the
file’s coding system by not trusting lseek+SEEK_END, which is
unreliable in /proc or when the file is mutating.

(cherry picked from commit 6a9dbed40ccebc18fda6078058b1978e29ef98fa)
src/fileio.c