From a3177c870aa97d9ce28b586fe65ecd681e8774f1 Mon Sep 17 00:00:00 2001 From: curme Date: Wed, 11 Nov 2020 21:41:28 +0800 Subject: [PATCH] fix: curl async http client empty-valued header --- tornado/curl_httpclient.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tornado/curl_httpclient.py b/tornado/curl_httpclient.py index 3860944956..1a98acedf2 100644 --- a/tornado/curl_httpclient.py +++ b/tornado/curl_httpclient.py @@ -351,6 +351,7 @@ def _curl_setup_request( pycurl.HTTPHEADER, [ "%s: %s" % (native_str(k), native_str(v)) + if v is not '' else "%s;" % native_str(k) for k, v in request.headers.get_all() ], )