added more fixes.
This commit is contained in:
parent
1426d3283d
commit
967d1261cd
|
@ -1,14 +1,13 @@
|
||||||
--- nginx-1.13.2/src/os/unix/ngx_process_cycle.c 2016-07-05 08:56:16.000000000 -0700
|
diff --git a/src/os/unix/ngx_process_cycle.c b/src/os/unix/ngx_process_cycle.c
|
||||||
+++ nginx-1.13.2-patched/src/os/unix/ngx_process_cycle.c 2017-05-14 09:59:52.301108274 -0700
|
index 1710ea81..b379da9c 100644
|
||||||
@@ -304,11 +304,29 @@ ngx_single_process_cycle(ngx_cycle_t *cy
|
--- a/src/os/unix/ngx_process_cycle.c
|
||||||
|
+++ b/src/os/unix/ngx_process_cycle.c
|
||||||
|
@@ -304,11 +304,26 @@ ngx_single_process_cycle(ngx_cycle_t *cycle)
|
||||||
}
|
}
|
||||||
|
|
||||||
for ( ;; ) {
|
for ( ;; ) {
|
||||||
+ if (ngx_exiting) {
|
+ if (ngx_exiting) {
|
||||||
+ ngx_event_cancel_timers();
|
+ if (ngx_event_no_timers_left() == NGX_OK) {
|
||||||
+
|
|
||||||
+ if (ngx_event_timer_rbtree.root == ngx_event_timer_rbtree.sentinel)
|
|
||||||
+ {
|
|
||||||
+ ngx_log_error(NGX_LOG_NOTICE, cycle->log, 0, "exiting");
|
+ ngx_log_error(NGX_LOG_NOTICE, cycle->log, 0, "exiting");
|
||||||
+
|
+
|
||||||
+ for (i = 0; cycle->modules[i]; i++) {
|
+ for (i = 0; cycle->modules[i]; i++) {
|
||||||
|
@ -31,7 +30,7 @@
|
||||||
|
|
||||||
for (i = 0; cycle->modules[i]; i++) {
|
for (i = 0; cycle->modules[i]; i++) {
|
||||||
if (cycle->modules[i]->exit_process) {
|
if (cycle->modules[i]->exit_process) {
|
||||||
@@ -319,6 +337,19 @@ ngx_single_process_cycle(ngx_cycle_t *cy
|
@@ -319,6 +334,20 @@ ngx_single_process_cycle(ngx_cycle_t *cycle)
|
||||||
ngx_master_process_exit(cycle);
|
ngx_master_process_exit(cycle);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -43,6 +42,7 @@
|
||||||
+
|
+
|
||||||
+ if (!ngx_exiting) {
|
+ if (!ngx_exiting) {
|
||||||
+ ngx_exiting = 1;
|
+ ngx_exiting = 1;
|
||||||
|
+ ngx_set_shutdown_timer(cycle);
|
||||||
+ ngx_close_listening_sockets(cycle);
|
+ ngx_close_listening_sockets(cycle);
|
||||||
+ ngx_close_idle_connections(cycle);
|
+ ngx_close_idle_connections(cycle);
|
||||||
+ }
|
+ }
|
||||||
|
|
|
@ -0,0 +1,17 @@
|
||||||
|
--- redis-nginx-module-0.3.7/ngx_http_redis_module.c 2017-08-05 15:52:26.135688662 -0700
|
||||||
|
+++ redis-nginx-module-0.3.7-patched/ngx_http_redis_module.c 2017-08-05 15:53:21.338594155 -0700
|
||||||
|
@@ -1005,12 +1005,14 @@ ngx_http_redis_upstream_add(ngx_http_req
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
+#if (nginx_version < 1011006)
|
||||||
|
if (uscfp[i]->default_port
|
||||||
|
&& url->default_port
|
||||||
|
&& uscfp[i]->default_port != url->default_port)
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
return uscfp[i];
|
||||||
|
}
|
|
@ -528,6 +528,10 @@ mv ngx_http_redis-* redis-nginx-module-$ver || exit 1
|
||||||
cd redis-nginx-module-$ver
|
cd redis-nginx-module-$ver
|
||||||
echo "applying ngx_http_redis-$ver-variables_in_redis_pass.patch"
|
echo "applying ngx_http_redis-$ver-variables_in_redis_pass.patch"
|
||||||
patch -p1 < $root/patches/ngx_http_redis-$ver-variables_in_redis_pass.patch || exit 1
|
patch -p1 < $root/patches/ngx_http_redis-$ver-variables_in_redis_pass.patch || exit 1
|
||||||
|
|
||||||
|
echo
|
||||||
|
echo "applying ngx_http_redis-$ver-default_port_fix.patch"
|
||||||
|
patch -p1 < $root/patches/ngx_http_redis-$ver-default_port_fix.patch || exit 1
|
||||||
echo
|
echo
|
||||||
|
|
||||||
echo "applying ngx_http_redis-$ver-without_gzip.patch"
|
echo "applying ngx_http_redis-$ver-without_gzip.patch"
|
||||||
|
|
Loading…
Reference in New Issue