nginxtra 1.2.6.8 → 1.2.7.8

Sign up to get free protection for your applications and to get access to all the features.
Files changed (54) hide show
  1. data/bin/nginxtra +1 -1
  2. data/bin/nginxtra_rails +1 -1
  3. data/lib/nginxtra/version.rb +1 -1
  4. data/vendor/nginx/CHANGES +72 -0
  5. data/vendor/nginx/CHANGES.ru +76 -0
  6. data/vendor/nginx/LICENSE +2 -2
  7. data/vendor/nginx/auto/cc/msvc +0 -3
  8. data/vendor/nginx/auto/lib/geoip/conf +17 -2
  9. data/vendor/nginx/auto/lib/libgd/conf +1 -1
  10. data/vendor/nginx/auto/lib/pcre/conf +1 -0
  11. data/vendor/nginx/auto/lib/perl/make +1 -3
  12. data/vendor/nginx/auto/lib/zlib/conf +4 -1
  13. data/vendor/nginx/man/nginx.8 +2 -2
  14. data/vendor/nginx/src/core/nginx.h +2 -2
  15. data/vendor/nginx/src/core/ngx_conf_file.c +4 -19
  16. data/vendor/nginx/src/core/ngx_conf_file.h +1 -10
  17. data/vendor/nginx/src/core/ngx_cycle.c +2 -19
  18. data/vendor/nginx/src/core/ngx_file.c +4 -4
  19. data/vendor/nginx/src/core/ngx_inet.c +1 -1
  20. data/vendor/nginx/src/core/ngx_inet.h +1 -1
  21. data/vendor/nginx/src/core/ngx_radix_tree.c +202 -5
  22. data/vendor/nginx/src/core/ngx_radix_tree.h +9 -0
  23. data/vendor/nginx/src/event/modules/ngx_poll_module.c +2 -2
  24. data/vendor/nginx/src/event/ngx_event.c +4 -0
  25. data/vendor/nginx/src/event/ngx_event_openssl.c +27 -13
  26. data/vendor/nginx/src/http/modules/ngx_http_auth_basic_module.c +38 -49
  27. data/vendor/nginx/src/http/modules/ngx_http_fastcgi_module.c +44 -59
  28. data/vendor/nginx/src/http/modules/ngx_http_geo_module.c +310 -103
  29. data/vendor/nginx/src/http/modules/ngx_http_geoip_module.c +145 -15
  30. data/vendor/nginx/src/http/modules/ngx_http_gzip_filter_module.c +5 -1
  31. data/vendor/nginx/src/http/modules/ngx_http_headers_filter_module.c +1 -0
  32. data/vendor/nginx/src/http/modules/ngx_http_image_filter_module.c +27 -13
  33. data/vendor/nginx/src/http/modules/ngx_http_log_module.c +378 -40
  34. data/vendor/nginx/src/http/modules/ngx_http_map_module.c +7 -0
  35. data/vendor/nginx/src/http/modules/ngx_http_proxy_module.c +9 -7
  36. data/vendor/nginx/src/http/modules/ngx_http_scgi_module.c +1 -1
  37. data/vendor/nginx/src/http/modules/ngx_http_secure_link_module.c +15 -2
  38. data/vendor/nginx/src/http/modules/ngx_http_split_clients_module.c +1 -1
  39. data/vendor/nginx/src/http/modules/ngx_http_sub_filter_module.c +2 -2
  40. data/vendor/nginx/src/http/modules/ngx_http_upstream_keepalive_module.c +4 -0
  41. data/vendor/nginx/src/http/modules/ngx_http_upstream_least_conn_module.c +3 -1
  42. data/vendor/nginx/src/http/modules/ngx_http_uwsgi_module.c +1 -1
  43. data/vendor/nginx/src/http/modules/ngx_http_xslt_filter_module.c +2 -2
  44. data/vendor/nginx/src/http/modules/perl/Makefile.PL +3 -14
  45. data/vendor/nginx/src/http/modules/perl/nginx.pm +2 -2
  46. data/vendor/nginx/src/http/ngx_http_core_module.c +2 -1
  47. data/vendor/nginx/src/http/ngx_http_script.c +3 -7
  48. data/vendor/nginx/src/http/ngx_http_upstream.c +9 -0
  49. data/vendor/nginx/src/http/ngx_http_upstream_round_robin.c +3 -1
  50. data/vendor/nginx/src/http/ngx_http_variables.c +114 -0
  51. data/vendor/nginx/src/http/ngx_http_write_filter_module.c +1 -1
  52. data/vendor/nginx/src/os/unix/ngx_files.c +1 -1
  53. data/vendor/nginx/src/os/unix/ngx_user.c +13 -14
  54. metadata +2 -2
@@ -207,7 +207,7 @@ ngx_http_write_filter(ngx_http_request_t *r, ngx_chain_t *in)
207
207
  }
208
208
 
209
209
  if (r->limit_rate) {
210
- limit = r->limit_rate * (ngx_time() - r->start_sec + 1)
210
+ limit = (off_t) r->limit_rate * (ngx_time() - r->start_sec + 1)
211
211
  - (c->sent - clcf->limit_rate_after);
212
212
 
213
213
  if (limit <= 0) {
@@ -363,7 +363,7 @@ ngx_open_glob(ngx_glob_t *gl)
363
363
  {
364
364
  int n;
365
365
 
366
- n = glob((char *) gl->pattern, GLOB_NOSORT, NULL, &gl->pglob);
366
+ n = glob((char *) gl->pattern, 0, NULL, &gl->pglob);
367
367
 
368
368
  if (n == 0) {
369
369
  return NGX_OK;
@@ -28,30 +28,27 @@ ngx_libc_crypt(ngx_pool_t *pool, u_char *key, u_char *salt, u_char **encrypted)
28
28
  {
29
29
  char *value;
30
30
  size_t len;
31
- ngx_err_t err;
32
31
  struct crypt_data cd;
33
32
 
34
- ngx_set_errno(0);
35
-
36
33
  cd.initialized = 0;
37
34
  /* work around the glibc bug */
38
35
  cd.current_salt[0] = ~salt[0];
39
36
 
40
37
  value = crypt_r((char *) key, (char *) salt, &cd);
41
38
 
42
- err = ngx_errno;
43
-
44
- if (err == 0) {
39
+ if (value) {
45
40
  len = ngx_strlen(value) + 1;
46
41
 
47
42
  *encrypted = ngx_pnalloc(pool, len);
48
- if (*encrypted) {
49
- ngx_memcpy(*encrypted, value, len);
50
- return NGX_OK;
43
+ if (*encrypted == NULL) {
44
+ return NGX_ERROR;
51
45
  }
46
+
47
+ ngx_memcpy(*encrypted, value, len);
48
+ return NGX_OK;
52
49
  }
53
50
 
54
- ngx_log_error(NGX_LOG_CRIT, pool->log, err, "crypt_r() failed");
51
+ ngx_log_error(NGX_LOG_CRIT, pool->log, ngx_errno, "crypt_r() failed");
55
52
 
56
53
  return NGX_ERROR;
57
54
  }
@@ -75,18 +72,20 @@ ngx_libc_crypt(ngx_pool_t *pool, u_char *key, u_char *salt, u_char **encrypted)
75
72
 
76
73
  #endif
77
74
 
78
- ngx_set_errno(0);
79
-
80
75
  value = crypt((char *) key, (char *) salt);
81
76
 
82
77
  if (value) {
83
78
  len = ngx_strlen(value) + 1;
84
79
 
85
80
  *encrypted = ngx_pnalloc(pool, len);
86
- if (*encrypted) {
87
- ngx_memcpy(*encrypted, value, len);
81
+ if (*encrypted == NULL) {
82
+ #if (NGX_THREADS && NGX_NONREENTRANT_CRYPT)
83
+ ngx_mutex_unlock(ngx_crypt_mutex);
84
+ #endif
85
+ return NGX_ERROR;
88
86
  }
89
87
 
88
+ ngx_memcpy(*encrypted, value, len);
90
89
  #if (NGX_THREADS && NGX_NONREENTRANT_CRYPT)
91
90
  ngx_mutex_unlock(ngx_crypt_mutex);
92
91
  #endif
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nginxtra
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.6.8
4
+ version: 1.2.7.8
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -413,7 +413,7 @@ files:
413
413
  - vendor/nginx/src/os/unix/ngx_user.h
414
414
  - vendor/nginx/src/os/unix/ngx_writev_chain.c
415
415
  - vendor/nginx/src/os/unix/rfork_thread.S
416
- homepage: http://reasonnumber.com/nginxtra
416
+ homepage: https://github.com/mikestone/nginxtra
417
417
  licenses: []
418
418
  post_install_message:
419
419
  rdoc_options: []