]> git.kaiwu.me - nginx.git/commitdiff
For the sake of case/switch code readability, 'fall through'
authorMaxim Konovalov <maxim@nginx.com>
Mon, 19 Mar 2012 14:57:29 +0000 (14:57 +0000)
committerMaxim Konovalov <maxim@nginx.com>
Mon, 19 Mar 2012 14:57:29 +0000 (14:57 +0000)
comments added.

src/http/ngx_http_parse.c
src/http/ngx_http_upstream.c

index 876a437afe0e85abddd8d91a3f8857b72fcc480c..ace6cfe9ae66e1226a1fbc6c74047009f493771c 100644 (file)
@@ -1153,6 +1153,7 @@ ngx_http_parse_complex_uri(ngx_http_request_t *r, ngx_uint_t merge_slashes)
                 break;
             case '+':
                 r->plus_in_uri = 1;
+                /* fall through */
             default:
                 *u++ = ch;
                 break;
index 7e368c1c1b4684e84a4bd15b81ea4a35ffbe59a4..a5ed15c426d331979aa142c8df8dd06f89d8787d 100644 (file)
@@ -3312,6 +3312,8 @@ ngx_http_upstream_process_accel_expires(ngx_http_request_t *r,
         switch (n) {
         case 0:
             u->cacheable = 0;
+            /* fall through */
+
         case NGX_ERROR:
             return NGX_OK;
 
@@ -4460,6 +4462,8 @@ ngx_http_upstream_bind_set_slot(ngx_conf_t *cf, ngx_command_t *cmd,
     case NGX_DECLINED:
         ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
                            "invalid address \"%V\"", &value[1]);
+        /* fall through */
+
     default:
         return NGX_CONF_ERROR;
     }