From 7dc51206303e03e37ade64ee5e59cd35bed5b530 Mon Sep 17 00:00:00 2001 From: aamine Date: Mon, 17 Sep 2007 12:07:07 +0000 Subject: * lib/net/http.rb (HTTP::GenericRequest#initialize): check path is not nil. [ruby-dev:31149] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13466 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ lib/net/http.rb | 1 + 2 files changed, 6 insertions(+) diff --git a/ChangeLog b/ChangeLog index 48ef4fc4a1..f45b5b1093 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Mon Sep 17 21:06:03 2007 Minero Aoki + + * lib/net/http.rb (HTTP::GenericRequest#initialize): check path is + not nil. [ruby-dev:31149] + Mon Sep 17 21:00:51 2007 Minero Aoki * parse.y (ripper): rename event: arglist_* -> args_*. diff --git a/lib/net/http.rb b/lib/net/http.rb index 62b951db1a..6be3a7ca2d 100644 --- a/lib/net/http.rb +++ b/lib/net/http.rb @@ -1524,6 +1524,7 @@ module Net #:nodoc: @method = m @request_has_body = reqbody @response_has_body = resbody + raise ArgumentError, "no HTTP request path given" unless path raise ArgumentError, "HTTP request path is empty" if path.empty? @path = path initialize_http_header initheader -- cgit v1.2.3