{"action":"created","issue":{"url":"https://api.github.com/repos/indutny/node-spdy/issues/287","repository_url":"https://api.github.com/repos/indutny/node-spdy","labels_url":"https://api.github.com/repos/indutny/node-spdy/issues/287/labels{/name}","comments_url":"https://api.github.com/repos/indutny/node-spdy/issues/287/comments","events_url":"https://api.github.com/repos/indutny/node-spdy/issues/287/events","html_url":"https://github.com/indutny/node-spdy/pull/287","id":182115743,"number":287,"title":"Fix memory leak caused by misfiring callback","user":{"login":"anandsuresh","id":1027513,"avatar_url":"https://avatars.githubusercontent.com/u/1027513?v=3","gravatar_id":"","url":"https://api.github.com/users/anandsuresh","html_url":"https://github.com/anandsuresh","followers_url":"https://api.github.com/users/anandsuresh/followers","following_url":"https://api.github.com/users/anandsuresh/following{/other_user}","gists_url":"https://api.github.com/users/anandsuresh/gists{/gist_id}","starred_url":"https://api.github.com/users/anandsuresh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anandsuresh/subscriptions","organizations_url":"https://api.github.com/users/anandsuresh/orgs","repos_url":"https://api.github.com/users/anandsuresh/repos","events_url":"https://api.github.com/users/anandsuresh/events{/privacy}","received_events_url":"https://api.github.com/users/anandsuresh/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-10-10T21:06:04Z","updated_at":"2016-10-12T11:48:44Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/indutny/node-spdy/pulls/287","html_url":"https://github.com/indutny/node-spdy/pull/287","diff_url":"https://github.com/indutny/node-spdy/pull/287.diff","patch_url":"https://github.com/indutny/node-spdy/pull/287.patch"},"body":"Streams can be ended by calling the `.close()` or `.shutdown()` methods\r\non the Handle instances. Internally, both call the `.end()` method to\r\nend the stream. However, only the `.close()` method takes a callback\r\nthat eventually frees the HttpParser instance allocated to the stream\r\nsocket.\r\n\r\nIn the event that the `.shutdown()` method is called before calling the\r\n`.close()` method, the second call to `.end()` never fires the callback,\r\nresulting in the leaking of HttpParser instances along with all its\r\nreferences.\r\n\r\nThis commit fixes the issue by directly executing the callback provided\r\nto the `.close()` method in the event the `.shutdown()` method was\r\ncalled before the `.close()` method of the Handle instance."},"comment":{"url":"https://api.github.com/repos/indutny/node-spdy/issues/comments/253192190","html_url":"https://github.com/indutny/node-spdy/pull/287#issuecomment-253192190","issue_url":"https://api.github.com/repos/indutny/node-spdy/issues/287","id":253192190,"user":{"login":"indutny","id":238531,"avatar_url":"https://avatars.githubusercontent.com/u/238531?v=3","gravatar_id":"","url":"https://api.github.com/users/indutny","html_url":"https://github.com/indutny","followers_url":"https://api.github.com/users/indutny/followers","following_url":"https://api.github.com/users/indutny/following{/other_user}","gists_url":"https://api.github.com/users/indutny/gists{/gist_id}","starred_url":"https://api.github.com/users/indutny/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/indutny/subscriptions","organizations_url":"https://api.github.com/users/indutny/orgs","repos_url":"https://api.github.com/users/indutny/repos","events_url":"https://api.github.com/users/indutny/events{/privacy}","received_events_url":"https://api.github.com/users/indutny/received_events","type":"User","site_admin":false},"created_at":"2016-10-12T11:48:44Z","updated_at":"2016-10-12T11:48:44Z","body":"@anandsuresh the tests doesn't seem to fail without changes to `lib/` folder... I clearly see the issue here, but looks like the tests don't reproduce it."}}
{"actor":{"display_login":"indutny"}}