]> git.kaiwu.me - nginx.git/commitdiff
Core: fixed memory leak on error, missed in c3f60d618c17.
authorMaxim Dounin <mdounin@mdounin.ru>
Fri, 19 Jul 2019 14:50:00 +0000 (17:50 +0300)
committerMaxim Dounin <mdounin@mdounin.ru>
Fri, 19 Jul 2019 14:50:00 +0000 (17:50 +0300)
Found by Coverity (CID 1451664).

src/core/ngx_hash.c

index d684e70577742978d3073abdbbf8a5c4b344579b..d9c157c1dc7e47f9e0cd5173c5a373edd2c3f865 100644 (file)
@@ -358,6 +358,7 @@ found:
                           "could not build %s, you should "
                           "increase %s_max_size: %i",
                           hinit->name, hinit->name, hinit->max_size);
+            ngx_free(test);
             return NGX_ERROR;
         }