diff options
author | Sergey Kandaurov <pluknet@nginx.com> | 2018-06-04 18:47:54 +0300 |
---|---|---|
committer | Sergey Kandaurov <pluknet@nginx.com> | 2018-06-04 18:47:54 +0300 |
commit | dac90a4bff8404e8097249a1ee444b77580f43ba (patch) | |
tree | 294626e09ab428a511b9b689772bf628ca1f2892 /src/core/ngx_buf.c | |
parent | 7b9bc5d4d1c061095a2391dbe32cf4d205c031bc (diff) | |
download | nginx-dac90a4bff8404e8097249a1ee444b77580f43ba.tar.gz nginx-dac90a4bff8404e8097249a1ee444b77580f43ba.zip |
Leave chain in ngx_chain_add_copy() in consistent state on errors.
Diffstat (limited to 'src/core/ngx_buf.c')
-rw-r--r-- | src/core/ngx_buf.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/core/ngx_buf.c b/src/core/ngx_buf.c index 1862a0606..c3783c446 100644 --- a/src/core/ngx_buf.c +++ b/src/core/ngx_buf.c @@ -137,6 +137,7 @@ ngx_chain_add_copy(ngx_pool_t *pool, ngx_chain_t **chain, ngx_chain_t *in) while (in) { cl = ngx_alloc_chain_link(pool); if (cl == NULL) { + *ll = NULL; return NGX_ERROR; } |