From 19114b03788f310dfc5115c9bc438b0ba7ac5491 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Sun, 10 Sep 2017 12:42:38 -0700 Subject: [PATCH] Fixed bug 3813 - gcc7 fallthrough warnings in SDL_iconv.c and SDL_pixels.c --- src/stdlib/SDL_iconv.c | 2 ++ src/video/SDL_pixels.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/stdlib/SDL_iconv.c b/src/stdlib/SDL_iconv.c index 86a895a18..cbd5d8a05 100644 --- a/src/stdlib/SDL_iconv.c +++ b/src/stdlib/SDL_iconv.c @@ -798,6 +798,7 @@ SDL_iconv(SDL_iconv_t cd, if (ch > 0x10FFFF) { ch = UNKNOWN_UNICODE; } + /* fallthrough */ case ENCODING_UCS4BE: if (ch > 0x7FFFFFFF) { ch = UNKNOWN_UNICODE; @@ -819,6 +820,7 @@ SDL_iconv(SDL_iconv_t cd, if (ch > 0x10FFFF) { ch = UNKNOWN_UNICODE; } + /* fallthrough */ case ENCODING_UCS4LE: if (ch > 0x7FFFFFFF) { ch = UNKNOWN_UNICODE; diff --git a/src/video/SDL_pixels.c b/src/video/SDL_pixels.c index d552e31bc..13cd75abe 100644 --- a/src/video/SDL_pixels.c +++ b/src/video/SDL_pixels.c @@ -326,7 +326,7 @@ SDL_MasksToPixelFormatEnum(int bpp, Uint32 Rmask, Uint32 Gmask, Uint32 Bmask, if (Rmask == 0) { return SDL_PIXELFORMAT_RGB555; } - /* Fall through to 16-bit checks */ + /* fallthrough */ case 16: if (Rmask == 0) { return SDL_PIXELFORMAT_RGB565;