diff options
author | Igor Sysoev <igor@sysoev.ru> | 2003-10-22 16:38:26 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2003-10-22 16:38:26 +0000 |
commit | dc9dd434aa1cfd24a98265742ff0ed4aeefc1f05 (patch) | |
tree | ceedf7b247bf2d5291da9c0cc2243fd3c3e505a9 /src/core/ngx_hunk.h | |
parent | 5bf3d25d69ecdbccaa98beeb089a7a6850529b89 (diff) | |
download | nginx-dc9dd434aa1cfd24a98265742ff0ed4aeefc1f05.tar.gz nginx-dc9dd434aa1cfd24a98265742ff0ed4aeefc1f05.zip |
nginx-0.0.1-2003-10-22-20:38:26 import
Diffstat (limited to 'src/core/ngx_hunk.h')
-rw-r--r-- | src/core/ngx_hunk.h | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/src/core/ngx_hunk.h b/src/core/ngx_hunk.h index 940241be7..abbdcfe48 100644 --- a/src/core/ngx_hunk.h +++ b/src/core/ngx_hunk.h @@ -99,31 +99,30 @@ ngx_hunk_t *ngx_create_temp_hunk(ngx_pool_t *pool, int size, #define ngx_alloc_hunk(pool) ngx_palloc(pool, sizeof(ngx_hunk_t)) #define ngx_calloc_hunk(pool) ngx_pcalloc(pool, sizeof(ngx_hunk_t)) -#define ngx_alloc_chain_entry(pool) ngx_palloc(pool, sizeof(ngx_chain_t)) -#define ngx_add_hunk_to_chain(chain, h, pool, error) \ +#define ngx_alloc_chain_link(pool) ngx_palloc(pool, sizeof(ngx_chain_t)) + + +#define ngx_alloc_link_and_set_hunk(chain, h, pool, error) \ do { \ - ngx_test_null(chain, ngx_alloc_chain_entry(pool), error); \ + ngx_test_null(chain, ngx_alloc_chain_link(pool), error); \ chain->hunk = h; \ chain->next = NULL; \ } while (0); -#define ngx_alloc_ce_and_set_hunk ngx_add_hunk_to_chain - -#define ngx_chain_add_ce(chain, last, ce) \ +#define ngx_chain_add_link(chain, last, cl) \ if (chain) { \ - *last = ce; \ + *last = cl; \ } else { \ - chain = ce; \ + chain = cl; \ } \ - last = &ce->next + last = &cl->next -int ngx_chain_add_copy(ngx_pool_t *pool, ngx_chain_t **ch, ngx_chain_t *in); +int ngx_chain_add_copy(ngx_pool_t *pool, ngx_chain_t **chain, ngx_chain_t *in); void ngx_chain_update_chains(ngx_chain_t **free, ngx_chain_t **busy, ngx_chain_t **out, ngx_hunk_tag_t tag); - #endif /* _NGX_HUNK_H_INCLUDED_ */ |