From: Andy Shevchenko Date: Fri, 16 Feb 2018 21:07:11 +0000 (+0200) Subject: lib/vsprintf: Mark expected switch fall-through X-Git-Tag: Ubuntu-5.4-5.4.0-11.14~5233^2~1^2~1 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=7e6bd6f3dcf913460a0a0ae7f260a8280001dd80;p=mirror_ubuntu-focal-kernel.git lib/vsprintf: Mark expected switch fall-through In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Link: http://lkml.kernel.org/r/20180216210711.79901-9-andriy.shevchenko@linux.intel.com To: "Tobin C . Harding" To: linux@rasmusvillemoes.dk To: Joe Perches To: linux-kernel@vger.kernel.org To: Andrew Morton Signed-off-by: Andy Shevchenko Signed-off-by: Petr Mladek --- diff --git a/lib/vsprintf.c b/lib/vsprintf.c index 97be2d07297a..38a71df48d48 100644 --- a/lib/vsprintf.c +++ b/lib/vsprintf.c @@ -2092,6 +2092,7 @@ qualifier: case 'x': spec->flags |= SMALL; + /* fall through */ case 'X': spec->base = 16; @@ -3046,8 +3047,10 @@ int vsscanf(const char *buf, const char *fmt, va_list args) break; case 'i': base = 0; + /* fall through */ case 'd': is_sign = true; + /* fall through */ case 'u': break; case '%':