@@ -148,6 +148,7 @@ void* ngx_http_c_func_get_query_param(ngx_http_c_func_ctx_t *ctx, const char *ke
148148void * ngx_http_c_func_palloc (ngx_http_c_func_ctx_t * ctx , size_t size );
149149void * ngx_http_c_func_pcalloc (ngx_http_c_func_ctx_t * ctx , size_t size );
150150
151+ uintptr_t ngx_http_c_func_shmtx_trylock (void * shared_mem );
151152void ngx_http_c_func_shmtx_lock (void * shared_mem );
152153void ngx_http_c_func_shmtx_unlock (void * shared_mem );
153154void * ngx_http_c_func_shm_alloc (void * shared_mem , size_t size );
@@ -501,7 +502,7 @@ ngx_http_c_func_post_configuration(ngx_conf_t *cf) {
501502static ngx_int_t
502503ngx_http_c_func_pre_configuration (ngx_conf_t * cf ) {
503504
504- #ifndef ngx_http_c_func_module_version_5
505+ #ifndef ngx_http_c_func_module_version_6
505506 ngx_conf_log_error (NGX_LOG_EMERG , cf , 0 , "%s" , "the latest ngx_http_c_func_module.h not found in the c header path, \
506507 please copy latest ngx_http_c_func_module.h to your /usr/include or /usr/local/include or relavent header search path \
507508 with read and write permission." );
@@ -1125,6 +1126,11 @@ ngx_http_c_func_pcalloc(ngx_http_c_func_ctx_t *ctx, size_t size) {
11251126 return ngx_pcalloc ( ((ngx_http_request_t * )ctx -> __r__ )-> pool , size );
11261127}
11271128
1129+ uintptr_t
1130+ ngx_http_c_func_shmtx_trylock (void * shared_mem ) {
1131+ return ngx_shmtx_trylock (& ((ngx_http_c_func_http_shm_t * )shared_mem )-> shpool -> mutex );
1132+ }
1133+
11281134void
11291135ngx_http_c_func_shmtx_lock (void * shared_mem ) {
11301136 ngx_shmtx_lock (& ((ngx_http_c_func_http_shm_t * )shared_mem )-> shpool -> mutex );
0 commit comments