summaryrefslogtreecommitdiff
path: root/contrib/libdiff/lib/diff_atomize_text.c
AgeCommit message (Collapse)Author
2024-05-20libdiff: Detect and recover from file truncation.Dag-Erling Smørgrav
If a memory-mapped file is truncated before we get to the end, the atomizer may catch SIGBUS. Detect that, reduce the input length to what we were actually able to read, and set a flag so the caller can take further action (e.g. warn the user and / or start over). Sponsored by: Klara, Inc. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D45217
2024-03-11Add 'contrib/libdiff/' from commit '9eb461aa4b61ab47855b2cee9e5b626a76888b5e'Dag-Erling Smørgrav
git-subtree-dir: contrib/libdiff git-subtree-mainline: f6d489f402c320f1a6eaa473491a0b8c3878113e git-subtree-split: 9eb461aa4b61ab47855b2cee9e5b626a76888b5e Reviewed by: imp Sponsored by: Klara, Inc.