title: HTTPS request Memory leak with CurlAsyncHTTPClient
body: <p>My handler file</p>
  
  <pre><code># -*- coding:utf-8 -*-
  import sys
  from tornado import gen, web, httpclient
  
  url = "https://mdetail.tmall.com/templates/pages/desc?id=527485572414"
  
  class SearchHandler(web.RequestHandler):
      @gen.coroutine
      def get(self):
          async_client = httpclient.AsyncHTTPClient()
          print sys.getrefcount(async_client) # The first time less than 10, then always bigger than 200
          req = httpclient.HTTPRequest(url, "GET", headers=headers)
          req_lists = [async_client.fetch(req) for _ in range(200)]
          r = yield req_lists
          print sys.getrefcount(async_client) # always bigger than 200
          # The longer req_lists, the more memory will be consumed, and never decrease
  </code></pre>
  
  <p>configure file</p>
  
  <pre><code>tornado.httpclient.AsyncHTTPClient.configure(client, max_clients=1000)
  </code></pre>
  
  <p>if my client is <strong>"tornado.curl_httpclient.CurlAsyncHTTPClient"</strong>, Then when I visit my handler in broswer, <strong>htop</strong> shows memory increase about 6GB,as long as the process running, memory usage never decrease</p>
  
  <p>If I set <strong>range(200)</strong> to <strong>range(500)</strong> or higher, Memory usage grows higher</p>
  
  <p>if my cline is <strong>None</strong>, memory barely increase</p>
  
  <p>I found only fetch the <strong>https://</strong> will have memory issue</p>
  
  <p>How can I slove the momory problem with <strong>CurlAsyncHTTPClient</strong>?</p>
  
  <p>Environment:</p>
  
  <pre><code>Ubuntu 16.10 x64
  python2.7.12
  Tornado 4.5.1
  </code></pre>