mirror of
https://github.com/nim-lang/Nim.git
synced 2026-01-07 21:43:33 +00:00
fix #13894, httpclient hang on Http204
This commit is contained in:
committed by
Dominik Picheta
parent
c835c8c4e7
commit
3036ec9c44
@@ -818,7 +818,7 @@ proc parseResponse(client: HttpClient | AsyncHttpClient,
|
||||
if not fullyRead:
|
||||
httpError("Connection was closed before full request has been made")
|
||||
|
||||
if getBody:
|
||||
if getBody and result.code != Http204:
|
||||
when client is HttpClient:
|
||||
client.bodyStream = newStringStream()
|
||||
result.bodyStream = client.bodyStream
|
||||
|
||||
Reference in New Issue
Block a user