Fix memory leak in HTTP client

Credit to Damien Vandenbossche and Thomas Lemarchand @tlemarchand for discovery and fix.
This commit is contained in:
Mike Place 2017-01-20 13:57:28 -07:00
parent dfe6dfe963
commit c46bf85518
No known key found for this signature in database
GPG key ID: 9136F4F13705CFD3

View file

@ -192,7 +192,7 @@ def query(url,
log_url = sanitize_url(url_full, hide_fields)
log.debug('Requesting URL {0} using {1} method'.format(log_url, method))
if method == 'POST':
if method == 'POST' and log.isEnabledFor(logging.TRACE):
# Make sure no secret fields show up in logs
if isinstance(data, dict):
log_data = data.copy()