From bf397c650b7fc0a3a07732a61f52a29a9c02fc7c Mon Sep 17 00:00:00 2001 From: Matthias Andree Date: Mon, 27 Oct 2003 08:29:34 +0100 Subject: [PATCH] Properly terminate /proc/tty/driver/serial output lines of known UARTS when the caller has no CAP_SYS_ADMIN capability. --- drivers/serial/serial_core.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/serial/serial_core.c b/drivers/serial/serial_core.c index dc0289c7739ef..02821f17036d3 100644 --- a/drivers/serial/serial_core.c +++ b/drivers/serial/serial_core.c @@ -1707,6 +1707,9 @@ static int uart_line_info(char *buf, struct uart_driver *drv, int i) strcat(stat_buf, "\n"); ret += sprintf(buf + ret, stat_buf); + } else { + strcat(buf, "\n"); + ret++; } #undef STATBIT #undef INFOBIT -- 2.53.0