Remove response body finalizer

it's unnecessary, see discussion in
https://gitlab.com/honeyryderchuck/httpx/-/merge_requests/159
This commit is contained in:
ojab 2021-08-30 14:07:36 +00:00
parent f18da78832
commit aa3be21c89
No known key found for this signature in database
GPG Key ID: 77315EBA95155D61

View File

@ -118,16 +118,6 @@ module HTTPX
@length = 0
@buffer = nil
@state = :idle
ObjectSpace.define_finalizer(self, self.class.finalize(@buffer))
end
def self.finalize(buffer)
proc {
return unless buffer
@buffer.close
@buffer.unlink if @buffer.respond_to?(:unlink)
}
end
def closed?