From cce8d6fdb4d7170a73763586daf6ac4f6b8fce2c Mon Sep 17 00:00:00 2001 From: Johannes Schindelin Date: Fri, 16 May 2008 14:03:30 +0100 Subject: mailsplit and mailinfo: gracefully handle NUL characters The function fgets() has a big problem with NUL characters: it reads them, but nobody will know if the NUL comes from the file stream, or was appended at the end of the line. So implement a custom read_line_with_nul() function. Noticed by Tommy Thorn. Signed-off-by: Johannes Schindelin Signed-off-by: Junio C Hamano --- t/t5100/nul | Bin 0 -> 91 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 t/t5100/nul (limited to 't/t5100') diff --git a/t/t5100/nul b/t/t5100/nul new file mode 100644 index 0000000000..3d40691787 Binary files /dev/null and b/t/t5100/nul differ -- cgit v1.2.3