diff options
author | 2020-09-03 20:43:15 +0000 | |
---|---|---|
committer | 2020-09-03 20:43:15 +0000 | |
commit | 30fa4bfa1d93f60689c0c47c0e532f2fc5cae39b (patch) | |
tree | e62635ab2894ae0057f41ed472a2402872371802 /regress/roff/char | |
parent | b71589000b1859d45cf1f2c247dc91fabf4f6753 (diff) | |
download | mandoc-30fa4bfa1d93f60689c0c47c0e532f2fc5cae39b.tar.gz mandoc-30fa4bfa1d93f60689c0c47c0e532f2fc5cae39b.tar.zst mandoc-30fa4bfa1d93f60689c0c47c0e532f2fc5cae39b.zip |
Fix two issues with .po (page offset) formatting:
1. Truncate excessive offsets to a width reasonable in the context
of manual pages instead of printing excessively long lines
and sometimes causing assertion failures;
found in an afl run performed by Jan Schreiber <jes at posteo dot de>.
2. Remember both the requested and the applied page offset; otherwise,
subtracting an excessive width, then adding it again, would end up
with an incorrectly large offset.
While here, simplify the code by reverting the previous offset up front,
and also add some comments to make the general ideas easier to understand.
Diffstat (limited to 'regress/roff/char')
0 files changed, 0 insertions, 0 deletions