示例说明 nginx模块是执行configure时生成模块列表,保存在ngx_modules.c中,以下是我本机生成的模块列表 ngx_module_t *ngx_modules [] = { &ngx_core_module , &ngx_errlog_module , &ngx_conf_module , &ngx_events_module , &ngx_event_core_module , &ngx_epoll_module , &ngx_regex_module , &ng...
if (modules[m]->type != NGX_RTMP_MODULE) { continue; } module = modules[m]->ctx; if (module->create_srv_conf) { mconf = module->create_srv_conf(cf); if (mconf == NULL) { return NGX_CONF_ERROR; } ctx->srv_conf[modules[m]->ctx_index] = mconf; ...
* to free client modules from registering * disconnect callback */ h = ngx_array_push(&cmcf->events[NGX_RTMP_DISCONNECT]); if (h == NULL) { return NGX_ERROR; } *h = ngx_rtmp_cmd_disconnect_init; /* register AMF callbacks */ ncalls = sizeof(ngx_rtmp_cmd_map) / ...
This repo is a PUBLIC FORK. Contribute to firebase/nginx development by creating an account on GitHub.
modules perl ngx_http_access_module.c ngx_http_addition_filter_module.c ngx_http_auth_basic_module.c ngx_http_auth_request_module.c ngx_http_autoindex_module.c ngx_http_browser_module.c ngx_http_charset_filter_module.c ngx_http_chunked_filter_module.c ...
ngx_modules数组是在执行configure脚本后自动生成的,在objs/ngx_modules.c文件中。该数组即当前编译版本中的所有Nginx模块。 如果想让nginx支持Rtmp的话,需要在执行configure脚本时添加第三方库nginx-rtmp-module ./configure--add-module=/path/to/nginx-rtmp-module ...
struct ngx_module_s { ngx_uint_t ctx_index; //是该模块在同一类模块中的序号,用NGX_MODULE_V1初始化为NGX_MODULE_UNSET_INDEX(-1) ngx_uint_t index; //该模块在所有Nginx模块中的序号, 即在ngx_modules数组里的唯一索引,用NGX_MODULE_V1初始化为NGX_MODULE_UNSET_INDEX(-1) char *name; // 模...
staticchar*ngx_events_block(ngx_conf_t*cf,ngx_command_t*cmd,void*conf){char*rv;void***ctx;ngx_uint_t i;ngx_conf_t pcf;ngx_event_module_t*m;ngx_event_max_module=0;for(i=0;ngx_modules[i];i++){if(ngx_modules[i]->type!=NGX_EVENT_MODULE)continue;/* 1.初始化全部事件模块的c...
Nginx 有关 mirror 的代码位于文件 src/http/modules/ngx_http_mirror_module.c 文件,上述为文件中的 ngx_http_mirror_handler_internal 函数。在开启了 mirror 之后此函数会被执行,可见其内部主要通过 ngx_http_subrequest 发起 http 子请求来实现的。
}returnngx_http_output_filter(r, &out[0]); } 5 Reference www.evanmiller.org/nginx-modules-guide.html http://blog.sina.com.cn/s/blog_7303a1dc0100x70t.html -