aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_controller/rack_ext
diff options
context:
space:
mode:
authorJoshua Peek <josh@joshpeek.com>2009-02-07 00:08:28 -0600
committerJoshua Peek <josh@joshpeek.com>2009-02-07 00:08:28 -0600
commit2277fbedbea930fb8ce38ab7eb133de6fcc4a2d6 (patch)
tree784f2dfcd066eaa17a89cc435ec4de44393799c8 /actionpack/lib/action_controller/rack_ext
parent24f2e676f700b8a387c6f4c27acf172658cd7863 (diff)
downloadrails-2277fbedbea930fb8ce38ab7eb133de6fcc4a2d6.tar.gz
rails-2277fbedbea930fb8ce38ab7eb133de6fcc4a2d6.tar.bz2
rails-2277fbedbea930fb8ce38ab7eb133de6fcc4a2d6.zip
Temporarily bundle Rack 1.0 prerelease for testing
Diffstat (limited to 'actionpack/lib/action_controller/rack_ext')
-rw-r--r--actionpack/lib/action_controller/rack_ext/lock.rb21
-rw-r--r--actionpack/lib/action_controller/rack_ext/multipart.rb22
-rw-r--r--actionpack/lib/action_controller/rack_ext/parse_query.rb17
3 files changed, 0 insertions, 60 deletions
diff --git a/actionpack/lib/action_controller/rack_ext/lock.rb b/actionpack/lib/action_controller/rack_ext/lock.rb
deleted file mode 100644
index 9bf1889065..0000000000
--- a/actionpack/lib/action_controller/rack_ext/lock.rb
+++ /dev/null
@@ -1,21 +0,0 @@
-module Rack
- # Rack::Lock was commited to Rack core
- # http://github.com/rack/rack/commit/7409b0c
- # Remove this when Rack 1.0 is released
- unless defined? Lock
- class Lock
- FLAG = 'rack.multithread'.freeze
-
- def initialize(app, lock = Mutex.new)
- @app, @lock = app, lock
- end
-
- def call(env)
- old, env[FLAG] = env[FLAG], false
- @lock.synchronize { @app.call(env) }
- ensure
- env[FLAG] = old
- end
- end
- end
-end
diff --git a/actionpack/lib/action_controller/rack_ext/multipart.rb b/actionpack/lib/action_controller/rack_ext/multipart.rb
deleted file mode 100644
index 3b142307e9..0000000000
--- a/actionpack/lib/action_controller/rack_ext/multipart.rb
+++ /dev/null
@@ -1,22 +0,0 @@
-module Rack
- module Utils
- module Multipart
- class << self
- def parse_multipart_with_rewind(env)
- result = parse_multipart_without_rewind(env)
-
- begin
- env['rack.input'].rewind if env['rack.input'].respond_to?(:rewind)
- rescue Errno::ESPIPE
- # Handles exceptions raised by input streams that cannot be rewound
- # such as when using plain CGI under Apache
- end
-
- result
- end
-
- alias_method_chain :parse_multipart, :rewind
- end
- end
- end
-end
diff --git a/actionpack/lib/action_controller/rack_ext/parse_query.rb b/actionpack/lib/action_controller/rack_ext/parse_query.rb
deleted file mode 100644
index b1acef8e72..0000000000
--- a/actionpack/lib/action_controller/rack_ext/parse_query.rb
+++ /dev/null
@@ -1,17 +0,0 @@
-# Rack does not automatically cleanup Safari 2 AJAX POST body
-# This has not yet been commited to Rack, please +1 this ticket:
-# http://rack.lighthouseapp.com/projects/22435/tickets/19
-
-module Rack
- module Utils
- alias_method :parse_query_without_ajax_body_cleanup, :parse_query
- module_function :parse_query_without_ajax_body_cleanup
-
- def parse_query(qs, d = '&;')
- qs = qs.dup
- qs.chop! if qs[-1] == 0
- parse_query_without_ajax_body_cleanup(qs, d)
- end
- module_function :parse_query
- end
-end