mirror of
git://git.sv.gnu.org/coreutils.git
synced 2026-04-21 11:16:16 +02:00
tac: don't misbehave with multiple non-seekable inputs
* src/tac.c (copy_to_temp): Do not reuse the template buffer. Instead, scribble only on a freshly-xstrdup'd copy each time. Free that buffer both here, upon failure, and ... (tac_nonseekable): ...free the buffer in caller, upon success. * tests/misc/tac-2-nonseekable: New file. * tests/Makefile.am (TESTS): Add it. * NEWS (Bug fixes): Mention it. Reported by Ambrose Feinstein in http://debbugs.gnu.org/9762.
This commit is contained in:
@@ -274,6 +274,7 @@ TESTS = \
|
||||
misc/sum-sysv \
|
||||
misc/tac \
|
||||
misc/tac-continue \
|
||||
misc/tac-2-nonseekable \
|
||||
misc/tail \
|
||||
misc/tee \
|
||||
misc/tee-dash \
|
||||
|
||||
Reference in New Issue
Block a user