Permalink
Browse files

prevent crash on nginx older than 0.8.22

  • Loading branch information...
1 parent c46ddd6 commit 526d68e86395c7e022960f6f6b6e95dc92959813 @peter-leonov committed Sep 2, 2010
Showing with 6 additions and 2 deletions.
  1. +6 −2 js/tests/request-variables.js
@@ -34,8 +34,12 @@ NginxTests.requestVariables = function (r)
vars.http_host = 'blablabla'
t.eq(vars.http_host, '127.0.0.1:19090', 'vars.http_host')
- vars.limit_rate = "1024"
- t.eq(vars.limit_rate, "1024", '$limit_rate')
+ // see crashes/request-variables
+ if (Nginx.version >= 8022)
+ {
+ vars.limit_rate = "1024"
+ t.eq(vars.limit_rate, "1024", '$limit_rate')
+ }
})
Tests.oncomplete = function ()
{

0 comments on commit 526d68e

Please sign in to comment.