]> git.hungrycats.org Git - linux/commitdiff
Properly terminate /proc/tty/driver/serial output lines of known UARTS
authorMatthias Andree <matthias.andree@gmx.de>
Mon, 27 Oct 2003 07:29:34 +0000 (08:29 +0100)
committerMatthias Andree <matthias.andree@gmx.de>
Mon, 27 Oct 2003 07:29:34 +0000 (08:29 +0100)
when the caller has no CAP_SYS_ADMIN capability.

drivers/serial/serial_core.c

index dc0289c7739ef023e08c899c4181a0fd8023f029..02821f17036d3c3079e6ea8923a285fa5b157528 100644 (file)
@@ -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