Browse Source

Fixed bug 3815 - implicit-fallthrough warning - DUFFS_LOOP4 and friends

Sam Lantinga 7 years ago
parent
commit
5f48ce0b64
1 changed files with 4 additions and 4 deletions
  1. 4 4
      src/video/SDL_blit.h

+ 4 - 4
src/video/SDL_blit.h

@@ -488,10 +488,10 @@ do {                                                                    \
 #define DUFFS_LOOP4(pixel_copy_increment, width)                        \
 { int n = (width+3)/4;                                                  \
     switch (width & 3) {                                                \
-    case 0: do {    pixel_copy_increment;                               \
-    case 3:     pixel_copy_increment;                                   \
-    case 2:     pixel_copy_increment;                                   \
-    case 1:     pixel_copy_increment;                                   \
+    case 0: do {    pixel_copy_increment;   /* fallthrough */           \
+    case 3:     pixel_copy_increment;       /* fallthrough */           \
+    case 2:     pixel_copy_increment;       /* fallthrough */           \
+    case 1:     pixel_copy_increment;       /* fallthrough */           \
         } while (--n > 0);                                              \
     }                                                                   \
 }