{"action":"created","issue":{"url":"https://api.github.com/repos/fluffle/goirc/issues/90","repository_url":"https://api.github.com/repos/fluffle/goirc","labels_url":"https://api.github.com/repos/fluffle/goirc/issues/90/labels{/name}","comments_url":"https://api.github.com/repos/fluffle/goirc/issues/90/comments","events_url":"https://api.github.com/repos/fluffle/goirc/issues/90/events","html_url":"https://github.com/fluffle/goirc/issues/90","id":174967162,"number":90,"title":"Allow user to close connection if server doesn't close after to QUIT.","user":{"login":"jasonkeene","id":161453,"avatar_url":"https://avatars.githubusercontent.com/u/161453?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonkeene","html_url":"https://github.com/jasonkeene","followers_url":"https://api.github.com/users/jasonkeene/followers","following_url":"https://api.github.com/users/jasonkeene/following{/other_user}","gists_url":"https://api.github.com/users/jasonkeene/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonkeene/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonkeene/subscriptions","organizations_url":"https://api.github.com/users/jasonkeene/orgs","repos_url":"https://api.github.com/users/jasonkeene/repos","events_url":"https://api.github.com/users/jasonkeene/events{/privacy}","received_events_url":"https://api.github.com/users/jasonkeene/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-09-04T20:10:13Z","updated_at":"2016-09-14T23:44:29Z","closed_at":"2016-09-12T19:55:50Z","body":"It seems the only way to initiate a teardown of the connection is to call `conn.Quit()` which just sends the `QUIT` command to the server. If the server ignores this they can force connections to stay open until max file descriptors is hit. It would probably be best to send the `QUIT` command, wait for tcp close from the server, if it doesn't happen call `Close` on the `net.Conn`."},"comment":{"url":"https://api.github.com/repos/fluffle/goirc/issues/comments/247190850","html_url":"https://github.com/fluffle/goirc/issues/90#issuecomment-247190850","issue_url":"https://api.github.com/repos/fluffle/goirc/issues/90","id":247190850,"user":{"login":"jasonkeene","id":161453,"avatar_url":"https://avatars.githubusercontent.com/u/161453?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonkeene","html_url":"https://github.com/jasonkeene","followers_url":"https://api.github.com/users/jasonkeene/followers","following_url":"https://api.github.com/users/jasonkeene/following{/other_user}","gists_url":"https://api.github.com/users/jasonkeene/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonkeene/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonkeene/subscriptions","organizations_url":"https://api.github.com/users/jasonkeene/orgs","repos_url":"https://api.github.com/users/jasonkeene/repos","events_url":"https://api.github.com/users/jasonkeene/events{/privacy}","received_events_url":"https://api.github.com/users/jasonkeene/received_events","type":"User","site_admin":false},"created_at":"2016-09-14T23:44:29Z","updated_at":"2016-09-14T23:44:29Z","body":"@fluffle Since you made the method public, it might be a good idea to consider making it an [io.Closer](https://golang.org/pkg/io/#Closer). Not only is it more idiomatic go but you are silencing an error from the `net.Conn` here: https://github.com/fluffle/goirc/blob/734da360090a74ff5ca03ad2482ea2c065c6ee18/client/connection.go#L519 Propagating that up the the caller would be useful.\r\n\r\nI didn't run into any issues IRL. I could just see a malicious server not respecting `QUIT` and me getting a call at 3AM.\r\n\r\nThanks for the fix!"}}
{"actor":{"display_login":"jasonkeene"}}