Mercurial > hg > nginx
comparison src/core/ngx_hunk.h @ 154:eac26585476e
nginx-0.0.1-2003-10-22-11:05:29 import
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Wed, 22 Oct 2003 07:05:29 +0000 |
parents | 5afee0074707 |
children | 46eb23d9471d |
comparison
equal
deleted
inserted
replaced
153:c71aeb75c071 | 154:eac26585476e |
---|---|
32 /* in event state flush means to start to write the hunk */ | 32 /* in event state flush means to start to write the hunk */ |
33 #define NGX_HUNK_FLUSH 0x1000 | 33 #define NGX_HUNK_FLUSH 0x1000 |
34 /* last hunk */ | 34 /* last hunk */ |
35 #define NGX_HUNK_LAST 0x2000 | 35 #define NGX_HUNK_LAST 0x2000 |
36 #define NGX_HUNK_LAST_SHADOW 0x4000 | 36 #define NGX_HUNK_LAST_SHADOW 0x4000 |
37 #define NGX_HUNK_TEMP_FILE 0x8000 | |
37 | 38 |
38 | 39 |
40 typedef void * ngx_hunk_tag_t; | |
39 | 41 |
40 typedef struct ngx_hunk_s ngx_hunk_t; | 42 typedef struct ngx_hunk_s ngx_hunk_t; |
41 | 43 |
42 struct ngx_hunk_s { | 44 struct ngx_hunk_s { |
43 char *pos; | 45 char *pos; |
44 char *last; | 46 char *last; |
45 off_t file_pos; | 47 off_t file_pos; |
46 off_t file_last; | 48 off_t file_last; |
47 | 49 |
48 int type; | 50 int type; |
49 char *start; /* start of hunk */ | 51 char *start; /* start of hunk */ |
50 char *end; /* end of hunk */ | 52 char *end; /* end of hunk */ |
51 char *pre_start; /* start of pre-allocated hunk */ | 53 char *pre_start; /* start of pre-allocated hunk */ |
52 char *post_end; /* end of post-allocated hunk */ | 54 char *post_end; /* end of post-allocated hunk */ |
53 int tag; | 55 ngx_hunk_tag_t tag; |
54 ngx_file_t *file; | 56 ngx_file_t *file; |
55 ngx_hunk_t *shadow; | 57 ngx_hunk_t *shadow; |
58 /* STUB */ int num; | |
56 }; | 59 }; |
57 | 60 |
58 | 61 |
59 typedef struct ngx_chain_s ngx_chain_t; | 62 typedef struct ngx_chain_s ngx_chain_t; |
60 | 63 |
117 last = &ce->next | 120 last = &ce->next |
118 | 121 |
119 | 122 |
120 int ngx_chain_add_copy(ngx_pool_t *pool, ngx_chain_t **ch, ngx_chain_t *in); | 123 int ngx_chain_add_copy(ngx_pool_t *pool, ngx_chain_t **ch, ngx_chain_t *in); |
121 void ngx_chain_update_chains(ngx_chain_t **free, ngx_chain_t **busy, | 124 void ngx_chain_update_chains(ngx_chain_t **free, ngx_chain_t **busy, |
122 ngx_chain_t **out); | 125 ngx_chain_t **out, ngx_hunk_tag_t tag); |
123 | 126 |
124 | 127 |
125 | 128 |
126 #endif /* _NGX_HUNK_H_INCLUDED_ */ | 129 #endif /* _NGX_HUNK_H_INCLUDED_ */ |