Adjust read count so that a newline can be added afterwards

Signed-off-by: Erik Sjölund <erik.sjolund@gmail.com>
This commit is contained in:
Erik Sjölund
2019-08-11 16:44:26 +02:00
parent 3bc861cb11
commit 39ce3626e0

View File

@ -276,7 +276,7 @@ static void __attribute__((constructor)) init()
return; return;
} }
r = TEMP_FAILURE_RETRY (read (fd, buf, sizeof (buf))); r = TEMP_FAILURE_RETRY (read (fd, buf, sizeof (buf) - 1));
close (fd); close (fd);
if (r < 0) if (r < 0)
{ {