* lib/soap/soap.rb(SOAP::Env.getenv): allow upcase environment variable

as well as downcase one.

        * lib/soap/netHttpClient.rb(SOAP::NetHttpClient#proxy=): check URI.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5124 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nahi 2003-12-06 08:26:15 +00:00
parent 6ffd5fe37e
commit 2e2ef81934
3 changed files with 13 additions and 1 deletions

View File

@ -1,3 +1,10 @@
Sat Dec 6 17:23:00 2003 NAKAMURA, Hiroshi <nahi@ruby-lang.org>
* lib/soap/soap.rb(SOAP::Env.getenv): allow upcase environment variable
as well as downcase one.
* lib/soap/netHttpClient.rb(SOAP::NetHttpClient#proxy=): check URI.
Fri Dec 5 23:22:30 2003 Nobuyoshi Nakada <nobu@ruby-lang.org>
* lib/test/unit/assertions.rb (Test::Unit::Assertions::assert_raises,

View File

@ -40,6 +40,11 @@ class NetHttpClient
@proxy = nil
else
@proxy = URI.parse(proxy_str)
if @proxy.scheme == nil or @proxy.scheme.downcase != 'http' or
@proxy.host == nil or @proxy.port == nil
raise ArgumentError.new("unsupported proxy `#{proxy_str}'")
end
@proxy
end
end

View File

@ -100,7 +100,7 @@ end
module Env
def self.getenv(name)
ENV[name.downcase] || ENV[name]
ENV[name.downcase] || ENV[name.upcase]
end
use_proxy = getenv('soap_use_proxy') == 'on'