{"action":"created","comment":{"url":"https://api.github.com/repos/interiorem/cocaine-core/pulls/comments/189544237","pull_request_review_id":121741692,"id":189544237,"diff_hunk":"@@ -55,6 +56,8 @@ class readable_stream:\n \n     decoder_type m_decoder;\n \n+    synchronized<bool> m_stopped{false};","path":"include/cocaine/rpc/asio/readable_stream.hpp","position":12,"original_position":12,"commit_id":"45708eb559a14c221b3ef76bba379b3747f9a174","original_commit_id":"45708eb559a14c221b3ef76bba379b3747f9a174","user":{"login":"karitra","id":391972,"avatar_url":"https://avatars2.githubusercontent.com/u/391972?v=4","gravatar_id":"","url":"https://api.github.com/users/karitra","html_url":"https://github.com/karitra","followers_url":"https://api.github.com/users/karitra/followers","following_url":"https://api.github.com/users/karitra/following{/other_user}","gists_url":"https://api.github.com/users/karitra/gists{/gist_id}","starred_url":"https://api.github.com/users/karitra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/karitra/subscriptions","organizations_url":"https://api.github.com/users/karitra/orgs","repos_url":"https://api.github.com/users/karitra/repos","events_url":"https://api.github.com/users/karitra/events{/privacy}","received_events_url":"https://api.github.com/users/karitra/received_events","type":"User","site_admin":false},"body":"Could be generic `std::atomic<bool>` more  convenient? The same for `writable_stream`.","created_at":"2018-05-21T09:53:07Z","updated_at":"2018-05-21T09:55:49Z","html_url":"https://github.com/interiorem/cocaine-core/pull/1#discussion_r189544237","pull_request_url":"https://api.github.com/repos/interiorem/cocaine-core/pulls/1","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/interiorem/cocaine-core/pulls/comments/189544237"},"html":{"href":"https://github.com/interiorem/cocaine-core/pull/1#discussion_r189544237"},"pull_request":{"href":"https://api.github.com/repos/interiorem/cocaine-core/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/interiorem/cocaine-core/pulls/1","id":189315120,"html_url":"https://github.com/interiorem/cocaine-core/pull/1","diff_url":"https://github.com/interiorem/cocaine-core/pull/1.diff","patch_url":"https://github.com/interiorem/cocaine-core/pull/1.patch","issue_url":"https://api.github.com/repos/interiorem/cocaine-core/issues/1","number":1,"state":"open","locked":false,"title":"Fix race between socket close and async calls by stream","user":{"login":"shaitan","id":446423,"avatar_url":"https://avatars2.githubusercontent.com/u/446423?v=4","gravatar_id":"","url":"https://api.github.com/users/shaitan","html_url":"https://github.com/shaitan","followers_url":"https://api.github.com/users/shaitan/followers","following_url":"https://api.github.com/users/shaitan/following{/other_user}","gists_url":"https://api.github.com/users/shaitan/gists{/gist_id}","starred_url":"https://api.github.com/users/shaitan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shaitan/subscriptions","organizations_url":"https://api.github.com/users/shaitan/orgs","repos_url":"https://api.github.com/users/shaitan/repos","events_url":"https://api.github.com/users/shaitan/events{/privacy}","received_events_url":"https://api.github.com/users/shaitan/received_events","type":"User","site_admin":false},"body":"The race leads to crash when streams try to concurrently perform asynchronous operation on closed socket.","created_at":"2018-05-21T08:33:42Z","updated_at":"2018-05-21T09:55:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f87dd635706fa7e2cef89c615cad0d5979e29ae7","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":935031584,"url":"https://api.github.com/repos/interiorem/cocaine-core/labels/bug","name":"bug","color":"d73a4a","default":true}],"milestone":null,"commits_url":"https://api.github.com/repos/interiorem/cocaine-core/pulls/1/commits","review_comments_url":"https://api.github.com/repos/interiorem/cocaine-core/pulls/1/comments","review_comment_url":"https://api.github.com/repos/interiorem/cocaine-core/pulls/comments{/number}","comments_url":"https://api.github.com/repos/interiorem/cocaine-core/issues/1/comments","statuses_url":"https://api.github.com/repos/interiorem/cocaine-core/statuses/45708eb559a14c221b3ef76bba379b3747f9a174","head":{"label":"shaitan:pr/fix","ref":"pr/fix","sha":"45708eb559a14c221b3ef76bba379b3747f9a174","user":{"login":"shaitan","id":446423,"avatar_url":"https://avatars2.githubusercontent.com/u/446423?v=4","gravatar_id":"","url":"https://api.github.com/users/shaitan","html_url":"https://github.com/shaitan","followers_url":"https://api.github.com/users/shaitan/followers","following_url":"https://api.github.com/users/shaitan/following{/other_user}","gists_url":"https://api.github.com/users/shaitan/gists{/gist_id}","starred_url":"https://api.github.com/users/shaitan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shaitan/subscriptions","organizations_url":"https://api.github.com/users/shaitan/orgs","repos_url":"https://api.github.com/users/shaitan/repos","events_url":"https://api.github.com/users/shaitan/events{/privacy}","received_events_url":"https://api.github.com/users/shaitan/received_events","type":"User","site_admin":false},"repo":{"id":63803395,"name":"cocaine-core","full_name":"shaitan/cocaine-core","owner":{"login":"shaitan","id":446423,"avatar_url":"https://avatars2.githubusercontent.com/u/446423?v=4","gravatar_id":"","url":"https://api.github.com/users/shaitan","html_url":"https://github.com/shaitan","followers_url":"https://api.github.com/users/shaitan/followers","following_url":"https://api.github.com/users/shaitan/following{/other_user}","gists_url":"https://api.github.com/users/shaitan/gists{/gist_id}","starred_url":"https://api.github.com/users/shaitan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shaitan/subscriptions","organizations_url":"https://api.github.com/users/shaitan/orgs","repos_url":"https://api.github.com/users/shaitan/repos","events_url":"https://api.github.com/users/shaitan/events{/privacy}","received_events_url":"https://api.github.com/users/shaitan/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/shaitan/cocaine-core","description":"Cocaine Application Engine","fork":true,"url":"https://api.github.com/repos/shaitan/cocaine-core","forks_url":"https://api.github.com/repos/shaitan/cocaine-core/forks","keys_url":"https://api.github.com/repos/shaitan/cocaine-core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/shaitan/cocaine-core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/shaitan/cocaine-core/teams","hooks_url":"https://api.github.com/repos/shaitan/cocaine-core/hooks","issue_events_url":"https://api.github.com/repos/shaitan/cocaine-core/issues/events{/number}","events_url":"https://api.github.com/repos/shaitan/cocaine-core/events","assignees_url":"https://api.github.com/repos/shaitan/cocaine-core/assignees{/user}","branches_url":"https://api.github.com/repos/shaitan/cocaine-core/branches{/branch}","tags_url":"https://api.github.com/repos/shaitan/cocaine-core/tags","blobs_url":"https://api.github.com/repos/shaitan/cocaine-core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/shaitan/cocaine-core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/shaitan/cocaine-core/git/refs{/sha}","trees_url":"https://api.github.com/repos/shaitan/cocaine-core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/shaitan/cocaine-core/statuses/{sha}","languages_url":"https://api.github.com/repos/shaitan/cocaine-core/languages","stargazers_url":"https://api.github.com/repos/shaitan/cocaine-core/stargazers","contributors_url":"https://api.github.com/repos/shaitan/cocaine-core/contributors","subscribers_url":"https://api.github.com/repos/shaitan/cocaine-core/subscribers","subscription_url":"https://api.github.com/repos/shaitan/cocaine-core/subscription","commits_url":"https://api.github.com/repos/shaitan/cocaine-core/commits{/sha}","git_commits_url":"https://api.github.com/repos/shaitan/cocaine-core/git/commits{/sha}","comments_url":"https://api.github.com/repos/shaitan/cocaine-core/comments{/number}","issue_comment_url":"https://api.github.com/repos/shaitan/cocaine-core/issues/comments{/number}","contents_url":"https://api.github.com/repos/shaitan/cocaine-core/contents/{+path}","compare_url":"https://api.github.com/repos/shaitan/cocaine-core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/shaitan/cocaine-core/merges","archive_url":"https://api.github.com/repos/shaitan/cocaine-core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/shaitan/cocaine-core/downloads","issues_url":"https://api.github.com/repos/shaitan/cocaine-core/issues{/number}","pulls_url":"https://api.github.com/repos/shaitan/cocaine-core/pulls{/number}","milestones_url":"https://api.github.com/repos/shaitan/cocaine-core/milestones{/number}","notifications_url":"https://api.github.com/repos/shaitan/cocaine-core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/shaitan/cocaine-core/labels{/name}","releases_url":"https://api.github.com/repos/shaitan/cocaine-core/releases{/id}","deployments_url":"https://api.github.com/repos/shaitan/cocaine-core/deployments","created_at":"2016-07-20T18:06:23Z","updated_at":"2016-07-20T18:06:25Z","pushed_at":"2018-04-20T08:07:46Z","git_url":"git://github.com/shaitan/cocaine-core.git","ssh_url":"git@github.com:shaitan/cocaine-core.git","clone_url":"https://github.com/shaitan/cocaine-core.git","svn_url":"https://github.com/shaitan/cocaine-core","homepage":"","size":13843,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"lgpl-3.0","name":"GNU Lesser General Public License v3.0","spdx_id":"LGPL-3.0","url":"https://api.github.com/licenses/lgpl-3.0"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"interiorem:master","ref":"master","sha":"a160bc281cc3128da1a4b37945d5e0a409930724","user":{"login":"interiorem","id":17122620,"avatar_url":"https://avatars0.githubusercontent.com/u/17122620?v=4","gravatar_id":"","url":"https://api.github.com/users/interiorem","html_url":"https://github.com/interiorem","followers_url":"https://api.github.com/users/interiorem/followers","following_url":"https://api.github.com/users/interiorem/following{/other_user}","gists_url":"https://api.github.com/users/interiorem/gists{/gist_id}","starred_url":"https://api.github.com/users/interiorem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/interiorem/subscriptions","organizations_url":"https://api.github.com/users/interiorem/orgs","repos_url":"https://api.github.com/users/interiorem/repos","events_url":"https://api.github.com/users/interiorem/events{/privacy}","received_events_url":"https://api.github.com/users/interiorem/received_events","type":"Organization","site_admin":false},"repo":{"id":133667003,"name":"cocaine-core","full_name":"interiorem/cocaine-core","owner":{"login":"interiorem","id":17122620,"avatar_url":"https://avatars0.githubusercontent.com/u/17122620?v=4","gravatar_id":"","url":"https://api.github.com/users/interiorem","html_url":"https://github.com/interiorem","followers_url":"https://api.github.com/users/interiorem/followers","following_url":"https://api.github.com/users/interiorem/following{/other_user}","gists_url":"https://api.github.com/users/interiorem/gists{/gist_id}","starred_url":"https://api.github.com/users/interiorem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/interiorem/subscriptions","organizations_url":"https://api.github.com/users/interiorem/orgs","repos_url":"https://api.github.com/users/interiorem/repos","events_url":"https://api.github.com/users/interiorem/events{/privacy}","received_events_url":"https://api.github.com/users/interiorem/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/interiorem/cocaine-core","description":"Cocaine Application Engine","fork":true,"url":"https://api.github.com/repos/interiorem/cocaine-core","forks_url":"https://api.github.com/repos/interiorem/cocaine-core/forks","keys_url":"https://api.github.com/repos/interiorem/cocaine-core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/interiorem/cocaine-core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/interiorem/cocaine-core/teams","hooks_url":"https://api.github.com/repos/interiorem/cocaine-core/hooks","issue_events_url":"https://api.github.com/repos/interiorem/cocaine-core/issues/events{/number}","events_url":"https://api.github.com/repos/interiorem/cocaine-core/events","assignees_url":"https://api.github.com/repos/interiorem/cocaine-core/assignees{/user}","branches_url":"https://api.github.com/repos/interiorem/cocaine-core/branches{/branch}","tags_url":"https://api.github.com/repos/interiorem/cocaine-core/tags","blobs_url":"https://api.github.com/repos/interiorem/cocaine-core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/interiorem/cocaine-core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/interiorem/cocaine-core/git/refs{/sha}","trees_url":"https://api.github.com/repos/interiorem/cocaine-core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/interiorem/cocaine-core/statuses/{sha}","languages_url":"https://api.github.com/repos/interiorem/cocaine-core/languages","stargazers_url":"https://api.github.com/repos/interiorem/cocaine-core/stargazers","contributors_url":"https://api.github.com/repos/interiorem/cocaine-core/contributors","subscribers_url":"https://api.github.com/repos/interiorem/cocaine-core/subscribers","subscription_url":"https://api.github.com/repos/interiorem/cocaine-core/subscription","commits_url":"https://api.github.com/repos/interiorem/cocaine-core/commits{/sha}","git_commits_url":"https://api.github.com/repos/interiorem/cocaine-core/git/commits{/sha}","comments_url":"https://api.github.com/repos/interiorem/cocaine-core/comments{/number}","issue_comment_url":"https://api.github.com/repos/interiorem/cocaine-core/issues/comments{/number}","contents_url":"https://api.github.com/repos/interiorem/cocaine-core/contents/{+path}","compare_url":"https://api.github.com/repos/interiorem/cocaine-core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/interiorem/cocaine-core/merges","archive_url":"https://api.github.com/repos/interiorem/cocaine-core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/interiorem/cocaine-core/downloads","issues_url":"https://api.github.com/repos/interiorem/cocaine-core/issues{/number}","pulls_url":"https://api.github.com/repos/interiorem/cocaine-core/pulls{/number}","milestones_url":"https://api.github.com/repos/interiorem/cocaine-core/milestones{/number}","notifications_url":"https://api.github.com/repos/interiorem/cocaine-core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/interiorem/cocaine-core/labels{/name}","releases_url":"https://api.github.com/repos/interiorem/cocaine-core/releases{/id}","deployments_url":"https://api.github.com/repos/interiorem/cocaine-core/deployments","created_at":"2018-05-16T13:06:04Z","updated_at":"2018-05-16T13:06:07Z","pushed_at":"2018-05-21T08:33:43Z","git_url":"git://github.com/interiorem/cocaine-core.git","ssh_url":"git@github.com:interiorem/cocaine-core.git","clone_url":"https://github.com/interiorem/cocaine-core.git","svn_url":"https://github.com/interiorem/cocaine-core","homepage":"","size":13844,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"lgpl-3.0","name":"GNU Lesser General Public License v3.0","spdx_id":"LGPL-3.0","url":"https://api.github.com/licenses/lgpl-3.0"},"forks":0,"open_issues":1,"watchers":0,"default_branch":"v0.12.14"}},"_links":{"self":{"href":"https://api.github.com/repos/interiorem/cocaine-core/pulls/1"},"html":{"href":"https://github.com/interiorem/cocaine-core/pull/1"},"issue":{"href":"https://api.github.com/repos/interiorem/cocaine-core/issues/1"},"comments":{"href":"https://api.github.com/repos/interiorem/cocaine-core/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/interiorem/cocaine-core/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/interiorem/cocaine-core/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/interiorem/cocaine-core/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/interiorem/cocaine-core/statuses/45708eb559a14c221b3ef76bba379b3747f9a174"}},"author_association":"NONE"}}
{"actor":{"display_login":"karitra"}}