mirror of
https://github.com/HoneyryderChuck/httpx.git
synced 2025-08-10 00:01:27 -04:00
not making too much stuff up when closing a channel
This commit is contained in:
parent
0763242cce
commit
9ff6db30c6
@ -98,18 +98,9 @@ module HTTPX
|
||||
@io.to_io
|
||||
end
|
||||
|
||||
def close(hard = false)
|
||||
pr = @parser
|
||||
def close
|
||||
@parser.close
|
||||
transition(:closing)
|
||||
if hard || (pr && pr.empty?)
|
||||
pr.close
|
||||
@parser = nil
|
||||
else
|
||||
transition(:idle)
|
||||
@parser = pr
|
||||
parser.reenqueue!
|
||||
return
|
||||
end
|
||||
end
|
||||
|
||||
def reset
|
||||
|
Loading…
x
Reference in New Issue
Block a user