OpenBSD/src HtYTJ6d — usr.bin/mandoc read.c
When the last line of the input is empty and the previous line reduced the line input buffer to a length of one byte, do not write one byte past the end of the line input buffer. Minimal code to show the bug: printf ".ds X\n.X\n\n" | MALLOC_OPTIONS=C mandoc Bug found by bentley@ in the sysutils/rancid par(1) manual page.
Version | Delta | File | |
---|---|---|---|
1.183 | +3 | -1 | usr.bin/mandoc/read.c |
+3 | -1 | 1 files |