basic/terminal-util: fix output of files without a final newline
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 27 Apr 2018 07:39:53 +0000 (09:39 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 27 Apr 2018 08:06:24 +0000 (10:06 +0200)
commitf8360f335c3ff78da41e6316049e1562b0711f2e
tree75b161eb18bbcbe24ae6bb1f29a8996cd5e4cb2a
parent6aaab70f0c7af9a529a2433ad39fe9169883a391
basic/terminal-util: fix output of files without a final newline

If the main config file or one of the drop-ins did not have the final newline,
there would be no seperating empty line (or if this was the last file
displayed, our own output would end without the final newline, possibly running
into the subsequent prompt or such). copy_bytes() does not know anything about
lines, so let's just use a normal loop with read_line() and puts().
src/basic/terminal-util.c