* lib/cgi/core.rb: fix command-line option of
non-interactive terminal. [ruby-core:23016] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25216 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
19bad26c5a
commit
ae8ad5ae27
@ -1,3 +1,8 @@
|
|||||||
|
Sun Oct 4 00:59:52 2009 Takeyuki FUJIOKA <xibbar@ruby-lang.org>
|
||||||
|
|
||||||
|
* lib/cgi/core.rb: fix command-line option of
|
||||||
|
non-interactive terminal. [ruby-core:23016]
|
||||||
|
|
||||||
Sun Oct 4 00:40:18 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Sun Oct 4 00:40:18 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* lib/rake/contrib: added. [ruby-core:25918]
|
* lib/rake/contrib: added. [ruby-core:25918]
|
||||||
|
@ -555,12 +555,21 @@ class CGI
|
|||||||
%|(offline mode: enter name=value pairs on standard input)\n|
|
%|(offline mode: enter name=value pairs on standard input)\n|
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
readlines.join(' ').gsub(/\n/, '')
|
array = nil
|
||||||
end.gsub(/\\=/, '%3D').gsub(/\\&/, '%26')
|
begin
|
||||||
|
readlines
|
||||||
|
rescue
|
||||||
|
end
|
||||||
|
if not array.nil?
|
||||||
|
array.join(' ').gsub(/\n/n, '')
|
||||||
|
else
|
||||||
|
""
|
||||||
|
end
|
||||||
|
end.gsub(/\\=/n, '%3D').gsub(/\\&/n, '%26')
|
||||||
|
|
||||||
words = Shellwords.shellwords(string)
|
words = Shellwords.shellwords(string)
|
||||||
|
|
||||||
if words.find{|x| /=/.match(x) }
|
if words.find{|x| /=/n.match(x) }
|
||||||
words.join('&')
|
words.join('&')
|
||||||
else
|
else
|
||||||
words.join('+')
|
words.join('+')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user