{"action":"created","comment":{"url":"https://api.github.com/repos/tvheadend/tvheadend/pulls/comments/38507122","id":38507122,"diff_hunk":"@@ -952,6 +954,24 @@ subscription_done(void)\n  * *************************************************************************/\n \n /**\n+ * Update incoming byte count\n+ */\n+void subscription_add_bytes_in(th_subscription_t *s, size_t in)\n+{\n+  atomic_add(&s->ths_bytes_in, in);\n+  atomic_add_u64(&s->ths_total_bytes_in, in);","path":"src/subscriptions.c","position":54,"original_position":54,"commit_id":"f40c76acecc819458cdaf65bd8b1efbfc4ab1853","original_commit_id":"f40c76acecc819458cdaf65bd8b1efbfc4ab1853","user":{"login":"Jalle19","id":1106133,"avatar_url":"https://avatars.githubusercontent.com/u/1106133?v=3","gravatar_id":"","url":"https://api.github.com/users/Jalle19","html_url":"https://github.com/Jalle19","followers_url":"https://api.github.com/users/Jalle19/followers","following_url":"https://api.github.com/users/Jalle19/following{/other_user}","gists_url":"https://api.github.com/users/Jalle19/gists{/gist_id}","starred_url":"https://api.github.com/users/Jalle19/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jalle19/subscriptions","organizations_url":"https://api.github.com/users/Jalle19/orgs","repos_url":"https://api.github.com/users/Jalle19/repos","events_url":"https://api.github.com/users/Jalle19/events{/privacy}","received_events_url":"https://api.github.com/users/Jalle19/received_events","type":"User","site_admin":false},"body":"In your snippet it also seems like `ths_total_bytes_in` will never be updated?","created_at":"2015-09-02T08:03:53Z","updated_at":"2015-09-02T08:03:53Z","html_url":"https://github.com/tvheadend/tvheadend/pull/708#discussion_r38507122","pull_request_url":"https://api.github.com/repos/tvheadend/tvheadend/pulls/708","_links":{"self":{"href":"https://api.github.com/repos/tvheadend/tvheadend/pulls/comments/38507122"},"html":{"href":"https://github.com/tvheadend/tvheadend/pull/708#discussion_r38507122"},"pull_request":{"href":"https://api.github.com/repos/tvheadend/tvheadend/pulls/708"}}},"pull_request":{"url":"https://api.github.com/repos/tvheadend/tvheadend/pulls/708","id":43901839,"html_url":"https://github.com/tvheadend/tvheadend/pull/708","diff_url":"https://github.com/tvheadend/tvheadend/pull/708.diff","patch_url":"https://github.com/tvheadend/tvheadend/pull/708.patch","issue_url":"https://api.github.com/repos/tvheadend/tvheadend/issues/708","number":708,"state":"open","locked":false,"title":"include in/out fields in subscription_create_msg()","user":{"login":"Jalle19","id":1106133,"avatar_url":"https://avatars.githubusercontent.com/u/1106133?v=3","gravatar_id":"","url":"https://api.github.com/users/Jalle19","html_url":"https://github.com/Jalle19","followers_url":"https://api.github.com/users/Jalle19/followers","following_url":"https://api.github.com/users/Jalle19/following{/other_user}","gists_url":"https://api.github.com/users/Jalle19/gists{/gist_id}","starred_url":"https://api.github.com/users/Jalle19/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jalle19/subscriptions","organizations_url":"https://api.github.com/users/Jalle19/orgs","repos_url":"https://api.github.com/users/Jalle19/repos","events_url":"https://api.github.com/users/Jalle19/events{/privacy}","received_events_url":"https://api.github.com/users/Jalle19/received_events","type":"User","site_admin":false},"body":"Without this potential clients will have to use the poll mechanism to get continuous updates on the bitrate of subscriptions.\r\n\r\n@perexg I'd like to get this into the 4.0 branch as well, should I PR it or will you cherry-pick it?","created_at":"2015-09-01T17:13:12Z","updated_at":"2015-09-02T08:03:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":"dcd97a2fb93080902b801e2f473b767d86cfc8db","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/tvheadend/tvheadend/pulls/708/commits","review_comments_url":"https://api.github.com/repos/tvheadend/tvheadend/pulls/708/comments","review_comment_url":"https://api.github.com/repos/tvheadend/tvheadend/pulls/comments{/number}","comments_url":"https://api.github.com/repos/tvheadend/tvheadend/issues/708/comments","statuses_url":"https://api.github.com/repos/tvheadend/tvheadend/statuses/f40c76acecc819458cdaf65bd8b1efbfc4ab1853","head":{"label":"Jalle19:status-inout","ref":"status-inout","sha":"f40c76acecc819458cdaf65bd8b1efbfc4ab1853","user":{"login":"Jalle19","id":1106133,"avatar_url":"https://avatars.githubusercontent.com/u/1106133?v=3","gravatar_id":"","url":"https://api.github.com/users/Jalle19","html_url":"https://github.com/Jalle19","followers_url":"https://api.github.com/users/Jalle19/followers","following_url":"https://api.github.com/users/Jalle19/following{/other_user}","gists_url":"https://api.github.com/users/Jalle19/gists{/gist_id}","starred_url":"https://api.github.com/users/Jalle19/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jalle19/subscriptions","organizations_url":"https://api.github.com/users/Jalle19/orgs","repos_url":"https://api.github.com/users/Jalle19/repos","events_url":"https://api.github.com/users/Jalle19/events{/privacy}","received_events_url":"https://api.github.com/users/Jalle19/received_events","type":"User","site_admin":false},"repo":{"id":12043644,"name":"tvheadend","full_name":"Jalle19/tvheadend","owner":{"login":"Jalle19","id":1106133,"avatar_url":"https://avatars.githubusercontent.com/u/1106133?v=3","gravatar_id":"","url":"https://api.github.com/users/Jalle19","html_url":"https://github.com/Jalle19","followers_url":"https://api.github.com/users/Jalle19/followers","following_url":"https://api.github.com/users/Jalle19/following{/other_user}","gists_url":"https://api.github.com/users/Jalle19/gists{/gist_id}","starred_url":"https://api.github.com/users/Jalle19/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jalle19/subscriptions","organizations_url":"https://api.github.com/users/Jalle19/orgs","repos_url":"https://api.github.com/users/Jalle19/repos","events_url":"https://api.github.com/users/Jalle19/events{/privacy}","received_events_url":"https://api.github.com/users/Jalle19/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Jalle19/tvheadend","description":"Tvheadend is a TV streaming server for Linux supporting DVB-S, DVB-S2, DVB-C, DVB-T, ATSC, IPTV, and Analog video (V4L) as input sources.","fork":true,"url":"https://api.github.com/repos/Jalle19/tvheadend","forks_url":"https://api.github.com/repos/Jalle19/tvheadend/forks","keys_url":"https://api.github.com/repos/Jalle19/tvheadend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Jalle19/tvheadend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Jalle19/tvheadend/teams","hooks_url":"https://api.github.com/repos/Jalle19/tvheadend/hooks","issue_events_url":"https://api.github.com/repos/Jalle19/tvheadend/issues/events{/number}","events_url":"https://api.github.com/repos/Jalle19/tvheadend/events","assignees_url":"https://api.github.com/repos/Jalle19/tvheadend/assignees{/user}","branches_url":"https://api.github.com/repos/Jalle19/tvheadend/branches{/branch}","tags_url":"https://api.github.com/repos/Jalle19/tvheadend/tags","blobs_url":"https://api.github.com/repos/Jalle19/tvheadend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Jalle19/tvheadend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Jalle19/tvheadend/git/refs{/sha}","trees_url":"https://api.github.com/repos/Jalle19/tvheadend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Jalle19/tvheadend/statuses/{sha}","languages_url":"https://api.github.com/repos/Jalle19/tvheadend/languages","stargazers_url":"https://api.github.com/repos/Jalle19/tvheadend/stargazers","contributors_url":"https://api.github.com/repos/Jalle19/tvheadend/contributors","subscribers_url":"https://api.github.com/repos/Jalle19/tvheadend/subscribers","subscription_url":"https://api.github.com/repos/Jalle19/tvheadend/subscription","commits_url":"https://api.github.com/repos/Jalle19/tvheadend/commits{/sha}","git_commits_url":"https://api.github.com/repos/Jalle19/tvheadend/git/commits{/sha}","comments_url":"https://api.github.com/repos/Jalle19/tvheadend/comments{/number}","issue_comment_url":"https://api.github.com/repos/Jalle19/tvheadend/issues/comments{/number}","contents_url":"https://api.github.com/repos/Jalle19/tvheadend/contents/{+path}","compare_url":"https://api.github.com/repos/Jalle19/tvheadend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Jalle19/tvheadend/merges","archive_url":"https://api.github.com/repos/Jalle19/tvheadend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Jalle19/tvheadend/downloads","issues_url":"https://api.github.com/repos/Jalle19/tvheadend/issues{/number}","pulls_url":"https://api.github.com/repos/Jalle19/tvheadend/pulls{/number}","milestones_url":"https://api.github.com/repos/Jalle19/tvheadend/milestones{/number}","notifications_url":"https://api.github.com/repos/Jalle19/tvheadend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Jalle19/tvheadend/labels{/name}","releases_url":"https://api.github.com/repos/Jalle19/tvheadend/releases{/id}","created_at":"2013-08-11T22:32:06Z","updated_at":"2015-04-09T13:07:47Z","pushed_at":"2015-09-01T21:39:28Z","git_url":"git://github.com/Jalle19/tvheadend.git","ssh_url":"git@github.com:Jalle19/tvheadend.git","clone_url":"https://github.com/Jalle19/tvheadend.git","svn_url":"https://github.com/Jalle19/tvheadend","homepage":"http://www.lonelycoder.com/hts/tvheadend_overview.html","size":30396,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"tvheadend:master","ref":"master","sha":"22188857b022d9729e2d35833abe599554ac363e","user":{"login":"tvheadend","id":1908588,"avatar_url":"https://avatars.githubusercontent.com/u/1908588?v=3","gravatar_id":"","url":"https://api.github.com/users/tvheadend","html_url":"https://github.com/tvheadend","followers_url":"https://api.github.com/users/tvheadend/followers","following_url":"https://api.github.com/users/tvheadend/following{/other_user}","gists_url":"https://api.github.com/users/tvheadend/gists{/gist_id}","starred_url":"https://api.github.com/users/tvheadend/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tvheadend/subscriptions","organizations_url":"https://api.github.com/users/tvheadend/orgs","repos_url":"https://api.github.com/users/tvheadend/repos","events_url":"https://api.github.com/users/tvheadend/events{/privacy}","received_events_url":"https://api.github.com/users/tvheadend/received_events","type":"Organization","site_admin":false},"repo":{"id":1208360,"name":"tvheadend","full_name":"tvheadend/tvheadend","owner":{"login":"tvheadend","id":1908588,"avatar_url":"https://avatars.githubusercontent.com/u/1908588?v=3","gravatar_id":"","url":"https://api.github.com/users/tvheadend","html_url":"https://github.com/tvheadend","followers_url":"https://api.github.com/users/tvheadend/followers","following_url":"https://api.github.com/users/tvheadend/following{/other_user}","gists_url":"https://api.github.com/users/tvheadend/gists{/gist_id}","starred_url":"https://api.github.com/users/tvheadend/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tvheadend/subscriptions","organizations_url":"https://api.github.com/users/tvheadend/orgs","repos_url":"https://api.github.com/users/tvheadend/repos","events_url":"https://api.github.com/users/tvheadend/events{/privacy}","received_events_url":"https://api.github.com/users/tvheadend/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/tvheadend/tvheadend","description":"Tvheadend is a TV streaming server for Linux supporting DVB-S, DVB-S2, DVB-C, DVB-T, ATSC, IPTV,SAT>IP and other formats through the unix pipe as input sources.","fork":false,"url":"https://api.github.com/repos/tvheadend/tvheadend","forks_url":"https://api.github.com/repos/tvheadend/tvheadend/forks","keys_url":"https://api.github.com/repos/tvheadend/tvheadend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tvheadend/tvheadend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tvheadend/tvheadend/teams","hooks_url":"https://api.github.com/repos/tvheadend/tvheadend/hooks","issue_events_url":"https://api.github.com/repos/tvheadend/tvheadend/issues/events{/number}","events_url":"https://api.github.com/repos/tvheadend/tvheadend/events","assignees_url":"https://api.github.com/repos/tvheadend/tvheadend/assignees{/user}","branches_url":"https://api.github.com/repos/tvheadend/tvheadend/branches{/branch}","tags_url":"https://api.github.com/repos/tvheadend/tvheadend/tags","blobs_url":"https://api.github.com/repos/tvheadend/tvheadend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tvheadend/tvheadend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tvheadend/tvheadend/git/refs{/sha}","trees_url":"https://api.github.com/repos/tvheadend/tvheadend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tvheadend/tvheadend/statuses/{sha}","languages_url":"https://api.github.com/repos/tvheadend/tvheadend/languages","stargazers_url":"https://api.github.com/repos/tvheadend/tvheadend/stargazers","contributors_url":"https://api.github.com/repos/tvheadend/tvheadend/contributors","subscribers_url":"https://api.github.com/repos/tvheadend/tvheadend/subscribers","subscription_url":"https://api.github.com/repos/tvheadend/tvheadend/subscription","commits_url":"https://api.github.com/repos/tvheadend/tvheadend/commits{/sha}","git_commits_url":"https://api.github.com/repos/tvheadend/tvheadend/git/commits{/sha}","comments_url":"https://api.github.com/repos/tvheadend/tvheadend/comments{/number}","issue_comment_url":"https://api.github.com/repos/tvheadend/tvheadend/issues/comments{/number}","contents_url":"https://api.github.com/repos/tvheadend/tvheadend/contents/{+path}","compare_url":"https://api.github.com/repos/tvheadend/tvheadend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tvheadend/tvheadend/merges","archive_url":"https://api.github.com/repos/tvheadend/tvheadend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tvheadend/tvheadend/downloads","issues_url":"https://api.github.com/repos/tvheadend/tvheadend/issues{/number}","pulls_url":"https://api.github.com/repos/tvheadend/tvheadend/pulls{/number}","milestones_url":"https://api.github.com/repos/tvheadend/tvheadend/milestones{/number}","notifications_url":"https://api.github.com/repos/tvheadend/tvheadend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tvheadend/tvheadend/labels{/name}","releases_url":"https://api.github.com/repos/tvheadend/tvheadend/releases{/id}","created_at":"2010-12-30T12:45:11Z","updated_at":"2015-09-01T20:03:30Z","pushed_at":"2015-09-01T21:39:29Z","git_url":"git://github.com/tvheadend/tvheadend.git","ssh_url":"git@github.com:tvheadend/tvheadend.git","clone_url":"https://github.com/tvheadend/tvheadend.git","svn_url":"https://github.com/tvheadend/tvheadend","homepage":"https://tvheadend.org","size":75015,"stargazers_count":749,"watchers_count":749,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":407,"mirror_url":null,"open_issues_count":20,"forks":407,"open_issues":20,"watchers":749,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/tvheadend/tvheadend/pulls/708"},"html":{"href":"https://github.com/tvheadend/tvheadend/pull/708"},"issue":{"href":"https://api.github.com/repos/tvheadend/tvheadend/issues/708"},"comments":{"href":"https://api.github.com/repos/tvheadend/tvheadend/issues/708/comments"},"review_comments":{"href":"https://api.github.com/repos/tvheadend/tvheadend/pulls/708/comments"},"review_comment":{"href":"https://api.github.com/repos/tvheadend/tvheadend/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/tvheadend/tvheadend/pulls/708/commits"},"statuses":{"href":"https://api.github.com/repos/tvheadend/tvheadend/statuses/f40c76acecc819458cdaf65bd8b1efbfc4ab1853"}}}}