Created
August 1, 2011 16:14
-
-
Save courtenay/1118441 to your computer and use it in GitHub Desktop.
simple rack app
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'stringio' | |
class TestLeak | |
def self.call(env) | |
str = env["rack.input"].read | |
puts env.inspect | |
puts str | |
env["rack.input"] = nil | |
str = nil | |
GC.start | |
end | |
end | |
TestLeak.call({ 'rack.input' => StringIO.new("monkeys") }) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment