summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-01-10 11:34:40 +0000
committeryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-01-10 11:34:40 +0000
commit0b0aafce5df8e2da2f69da7bad096d0076f7db03 (patch)
tree959b39ad5860e9f2244299f2f77d4b01e56d1b38
parenteb87f155f651c197f218b8983250af7a3796e686 (diff)
Fix for the previous commit
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_1@26272 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--lib/webrick/httpstatus.rb5
-rw-r--r--test/webrick/test_cgi.rb4
-rw-r--r--version.h2
3 files changed, 6 insertions, 5 deletions
diff --git a/lib/webrick/httpstatus.rb b/lib/webrick/httpstatus.rb
index 325bfa8d65..f354b7d75d 100644
--- a/lib/webrick/httpstatus.rb
+++ b/lib/webrick/httpstatus.rb
@@ -13,8 +13,9 @@ module WEBrick
module HTTPStatus
class Status < StandardError
- def initialize(message, *rest)
- super(AccessLog.escape(message), *rest)
+ def initialize(*args)
+ args[0] = AccessLog.escape(args[0]) unless args.empty?
+ super(*args)
end
class << self
attr_reader :code, :reason_phrase
diff --git a/test/webrick/test_cgi.rb b/test/webrick/test_cgi.rb
index 50affcae91..2d7ad2d085 100644
--- a/test/webrick/test_cgi.rb
+++ b/test/webrick/test_cgi.rb
@@ -113,7 +113,7 @@ class TestWEBrickCGI < Test::Unit::TestCase
assert_match(%r{\AHTTP/\d.\d 400 Bad Request}, res)
s = log.call.each_line.grep(/ERROR bad URI/)[0]
assert_match(DumpPat, s)
- assert_not_match(CtrlPat, s)
+ refute_match(CtrlPat, s)
}
end
@@ -127,7 +127,7 @@ class TestWEBrickCGI < Test::Unit::TestCase
assert_match(%r{\AHTTP/\d.\d 400 Bad Request}, res)
s = log.call.each_line.grep(/ERROR bad header/)[0]
assert_match(DumpPat, s)
- assert_not_match(CtrlPat, s)
+ refute_match(CtrlPat, s)
}
end
end
diff --git a/version.h b/version.h
index dfafffad41..46cf3afa20 100644
--- a/version.h
+++ b/version.h
@@ -1,5 +1,5 @@
#define RUBY_VERSION "1.9.1"
-#define RUBY_PATCHLEVEL 377
+#define RUBY_PATCHLEVEL 378
#define RUBY_VERSION_MAJOR 1
#define RUBY_VERSION_MINOR 9
#define RUBY_VERSION_TEENY 1