@@ -207,8 +207,8 @@ ngx_http_unzip_chain_copy_range(ngx_chain_t *chain, ngx_chain_t **copy, off_t *l
207
207
void ngx_http_unzip_reclaim_chain (ngx_chain_t * cl , ngx_chain_t * * free );
208
208
void ngx_http_unzip_chain_advance (ngx_chain_t * chain , ngx_chain_t * copy );
209
209
210
- static char * ngx_http_unzip_command (ngx_conf_t * cf , ngx_command_t * cmd , void * conf );
211
- static void * ngx_http_unzip_create_loc_conf (ngx_conf_t * cf );
210
+ static char * ngx_upload_unzip_command (ngx_conf_t * cf , ngx_command_t * cmd , void * conf );
211
+ static void * ngx_upload_unzip_create_loc_conf (ngx_conf_t * cf );
212
212
213
213
static ngx_int_t ngx_http_unzip_start_handler (ngx_http_upload_ctx_t * u );
214
214
static void ngx_http_unzip_finish_handler (ngx_http_upload_ctx_t * u );
@@ -260,14 +260,14 @@ ngx_http_unzip_content_filter = {
260
260
261
261
static ngx_conf_post_handler_pt ngx_http_unzip_window_p = ngx_http_unzip_window ;
262
262
263
- static ngx_command_t ngx_http_unzip_filter_commands [] = { /* {{{ */
263
+ static ngx_command_t ngx_upload_unzip_filter_commands [] = { /* {{{ */
264
264
265
265
/*
266
266
* Enables unzipping of uploaded file
267
267
*/
268
268
{ ngx_string ("upload_unzip" ),
269
269
NGX_HTTP_LOC_CONF |NGX_CONF_TAKE1 ,
270
- ngx_http_unzip_command ,
270
+ ngx_upload_unzip_command ,
271
271
NGX_HTTP_LOC_CONF_OFFSET ,
272
272
0 ,
273
273
NULL },
@@ -327,7 +327,7 @@ static ngx_command_t ngx_http_unzip_filter_commands[] = { /* {{{ */
327
327
ngx_null_command
328
328
}; /* }}} */
329
329
330
- ngx_http_module_t ngx_http_unzip_filter_module_ctx = { /* {{{ */
330
+ ngx_http_module_t ngx_upload_unzip_filter_module_ctx = { /* {{{ */
331
331
NULL , /* preconfiguration */
332
332
NULL , /* postconfiguration */
333
333
@@ -337,14 +337,14 @@ ngx_http_module_t ngx_http_unzip_filter_module_ctx = { /* {{{ */
337
337
NULL , /* create server configuration */
338
338
NULL , /* merge server configuration */
339
339
340
- ngx_http_unzip_create_loc_conf , /* create location configuration */
340
+ ngx_upload_unzip_create_loc_conf , /* create location configuration */
341
341
NULL /* merge location configuration */
342
342
}; /* }}} */
343
343
344
- ngx_module_t ngx_http_unzip_filter_module = { /* {{{ */
344
+ ngx_module_t ngx_upload_unzip_filter_module = { /* {{{ */
345
345
NGX_MODULE_V1 ,
346
- & ngx_http_unzip_filter_module_ctx , /* module context */
347
- ngx_http_unzip_filter_commands , /* module directives */
346
+ & ngx_upload_unzip_filter_module_ctx , /* module context */
347
+ ngx_upload_unzip_filter_commands , /* module directives */
348
348
NGX_HTTP_MODULE , /* module type */
349
349
NULL , /* init master */
350
350
NULL , /* init module */
@@ -356,8 +356,8 @@ ngx_module_t ngx_http_unzip_filter_module = { /* {{{ */
356
356
NGX_MODULE_V1_PADDING
357
357
}; /* }}} */
358
358
359
- static char * /* {{{ ngx_http_unzip_command */
360
- ngx_http_unzip_command (ngx_conf_t * cf , ngx_command_t * cmd , void * conf )
359
+ static char * /* {{{ ngx_upload_unzip_command */
360
+ ngx_upload_unzip_command (ngx_conf_t * cf , ngx_command_t * cmd , void * conf )
361
361
{
362
362
ngx_unzip_conf_t * uzcf = conf ;
363
363
ngx_http_upload_loc_conf_t * ulcf ;
@@ -387,7 +387,7 @@ ngx_http_unzip_process_chain(ngx_unzip_ctx_t *ctx, ngx_chain_t *chain) {
387
387
ngx_buf_t * buf ;
388
388
ngx_unzip_conf_t * uzcf ;
389
389
390
- uzcf = ngx_http_get_module_loc_conf (ctx -> upload_ctx -> request , ngx_http_unzip_filter_module );
390
+ uzcf = ngx_http_get_module_loc_conf (ctx -> upload_ctx -> request , ngx_upload_unzip_filter_module );
391
391
392
392
while (chain != NULL ) {
393
393
for (buf = chain -> buf ; buf -> pos != buf -> last ; buf -> pos ++ ) {
@@ -859,10 +859,10 @@ ngx_http_unzip_start_handler(ngx_http_upload_ctx_t *u) {
859
859
ngx_unzip_ctx_t * ctx , * parent ;
860
860
ngx_http_upload_loc_conf_t * ulcf ;
861
861
862
- uzcf = ngx_http_get_module_loc_conf (u -> request , ngx_http_unzip_filter_module );
862
+ uzcf = ngx_http_get_module_loc_conf (u -> request , ngx_upload_unzip_filter_module );
863
863
ulcf = ngx_http_get_module_loc_conf (u -> request , ngx_http_upload_module );
864
864
865
- ctx = ngx_http_get_module_ctx (u -> request , ngx_http_unzip_filter_module );
865
+ ctx = ngx_http_get_module_ctx (u -> request , ngx_upload_unzip_filter_module );
866
866
867
867
parent = ctx ;
868
868
@@ -878,7 +878,7 @@ ngx_http_unzip_start_handler(ngx_http_upload_ctx_t *u) {
878
878
879
879
ctx -> parent = parent ;
880
880
881
- ngx_http_set_ctx (u -> request , ctx , ngx_http_unzip_filter_module );
881
+ ngx_http_set_ctx (u -> request , ctx , ngx_upload_unzip_filter_module );
882
882
883
883
ctx -> state = unzip_state_signature ;
884
884
ctx -> upload_ctx = u ;
@@ -910,7 +910,7 @@ static void /* {{{ ngx_http_unzip_finish_handler */
910
910
ngx_http_unzip_finish_handler (ngx_http_upload_ctx_t * u ) {
911
911
ngx_unzip_ctx_t * ctx ;
912
912
913
- ctx = ngx_http_get_module_ctx (u -> request , ngx_http_unzip_filter_module );
913
+ ctx = ngx_http_get_module_ctx (u -> request , ngx_upload_unzip_filter_module );
914
914
915
915
if (ctx -> state == unzip_state_file_data ) {
916
916
if (!ctx -> discard_data )
@@ -921,14 +921,14 @@ ngx_http_unzip_finish_handler(ngx_http_upload_ctx_t *u) {
921
921
922
922
ngx_upload_set_archive_path (u , & ctx -> prev_archive_path );
923
923
924
- ngx_http_set_ctx (u -> request , ctx -> parent , ngx_http_unzip_filter_module );
924
+ ngx_http_set_ctx (u -> request , ctx -> parent , ngx_upload_unzip_filter_module );
925
925
} /* }}} */
926
926
927
927
static void /* {{{ ngx_http_unzip_abort_handler */
928
928
ngx_http_unzip_abort_handler (ngx_http_upload_ctx_t * u ) {
929
929
ngx_unzip_ctx_t * ctx ;
930
930
931
- ctx = ngx_http_get_module_ctx (u -> request , ngx_http_unzip_filter_module );
931
+ ctx = ngx_http_get_module_ctx (u -> request , ngx_upload_unzip_filter_module );
932
932
933
933
if (ctx -> state == unzip_state_file_data ) {
934
934
if (!ctx -> discard_data )
@@ -939,20 +939,20 @@ ngx_http_unzip_abort_handler(ngx_http_upload_ctx_t *u) {
939
939
940
940
ngx_upload_set_archive_path (u , & ctx -> prev_archive_path );
941
941
942
- ngx_http_set_ctx (u -> request , ctx -> parent , ngx_http_unzip_filter_module );
942
+ ngx_http_set_ctx (u -> request , ctx -> parent , ngx_upload_unzip_filter_module );
943
943
} /* }}} */
944
944
945
945
static ngx_int_t /* {{{ ngx_http_unzip_data_handler */
946
946
ngx_http_unzip_data_handler (ngx_http_upload_ctx_t * u , ngx_chain_t * chain ) {
947
947
ngx_unzip_ctx_t * ctx ;
948
948
949
- ctx = ngx_http_get_module_ctx (u -> request , ngx_http_unzip_filter_module );
949
+ ctx = ngx_http_get_module_ctx (u -> request , ngx_upload_unzip_filter_module );
950
950
951
951
return ngx_http_unzip_process_chain (ctx , chain );
952
952
} /* }}} */
953
953
954
- static void * /* {{{ ngx_http_unzip_create_loc_conf */
955
- ngx_http_unzip_create_loc_conf (ngx_conf_t * cf )
954
+ static void * /* {{{ ngx_upload_unzip_create_loc_conf */
955
+ ngx_upload_unzip_create_loc_conf (ngx_conf_t * cf )
956
956
{
957
957
ngx_unzip_conf_t * conf ;
958
958
@@ -1028,7 +1028,7 @@ ngx_http_unzip_inflate_start(ngx_unzip_ctx_t *ctx) {
1028
1028
ctx -> stream .avail_in = 0 ;
1029
1029
ctx -> stream .next_in = Z_NULL ;
1030
1030
1031
- uzcf = ngx_http_get_module_loc_conf (ctx -> upload_ctx -> request , ngx_http_unzip_filter_module );
1031
+ uzcf = ngx_http_get_module_loc_conf (ctx -> upload_ctx -> request , ngx_upload_unzip_filter_module );
1032
1032
1033
1033
if (ctx -> output_buffer == NULL ) {
1034
1034
ctx -> output_buffer = ngx_create_temp_buf (ctx -> pool , uzcf -> bufs .size );
0 commit comments