From: Joe Perches Date: Tue, 25 Aug 2020 04:56:04 +0000 (-0700) Subject: lp: Avoid comma separated statements X-Git-Tag: v5.10-rc1~124^2~189 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c2fef5f845bef784f06d6dc2ee6a3fd013eaeee8;p=thirdparty%2Fkernel%2Flinux.git lp: Avoid comma separated statements Use semicolons and braces. Signed-off-by: Joe Perches Link: https://lore.kernel.org/r/850c60ea44927e8cb7604d178c613ff8fc667984.1598331148.git.joe@perches.com Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/char/lp.c b/drivers/char/lp.c index bd95aba1f9fe8..5f50e4072fae6 100644 --- a/drivers/char/lp.c +++ b/drivers/char/lp.c @@ -853,8 +853,10 @@ static void lp_console_write(struct console *co, const char *s, count--; do { written = parport_write(port, crlf, i); - if (written > 0) - i -= written, crlf += written; + if (written > 0) { + i -= written; + crlf += written; + } } while (i > 0 && (CONSOLE_LP_STRICT || written > 0)); } } while (count > 0 && (CONSOLE_LP_STRICT || written > 0));