comparison src/core/ngx_palloc.c @ 1317:276b981ca92f

fix memory leak, found by Coverity's Scan
author Igor Sysoev <igor@sysoev.ru>
date Thu, 19 Jul 2007 19:07:13 +0000
parents 103988cef757
children d65172100f6b
comparison
equal deleted inserted replaced
1316:f5bb5521d02c 1317:276b981ca92f
161 } 161 }
162 #endif 162 #endif
163 163
164 large = ngx_palloc(pool, sizeof(ngx_pool_large_t)); 164 large = ngx_palloc(pool, sizeof(ngx_pool_large_t));
165 if (large == NULL) { 165 if (large == NULL) {
166 ngx_free(p);
166 return NULL; 167 return NULL;
167 } 168 }
168 169
169 large->alloc = p; 170 large->alloc = p;
170 large->next = pool->large; 171 large->next = pool->large;