{"action":"created","comment":{"url":"https://api.github.com/repos/nmichaels/smear/pulls/comments/209453372","pull_request_review_id":145472454,"id":209453372,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwOTQ1MzM3Mg==","diff_hunk":"@@ -0,0 +1,510 @@\n+#include <stdlib.h>\n+#include <string.h>\n+#include <assert.h>\n+#include <stdio.h>\n+#include <pthread.h>\n+\n+#include \"cancellable.h\"\n+\n+#define HEAP_CHECK true // Set to false to save oodles of execution time.\n+","path":"src/cancelq/posix/cancellable.c","position":10,"original_position":10,"commit_id":"88d8c6e715897f3438be1aace8b1ec8f266137a7","original_commit_id":"88d8c6e715897f3438be1aace8b1ec8f266137a7","user":{"login":"natebragg","id":781307,"node_id":"MDQ6VXNlcjc4MTMwNw==","avatar_url":"https://avatars1.githubusercontent.com/u/781307?v=4","gravatar_id":"","url":"https://api.github.com/users/natebragg","html_url":"https://github.com/natebragg","followers_url":"https://api.github.com/users/natebragg/followers","following_url":"https://api.github.com/users/natebragg/following{/other_user}","gists_url":"https://api.github.com/users/natebragg/gists{/gist_id}","starred_url":"https://api.github.com/users/natebragg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/natebragg/subscriptions","organizations_url":"https://api.github.com/users/natebragg/orgs","repos_url":"https://api.github.com/users/natebragg/repos","events_url":"https://api.github.com/users/natebragg/events{/privacy}","received_events_url":"https://api.github.com/users/natebragg/received_events","type":"User","site_admin":false},"body":"Maybe wrap this in an `#ifdef DEBUG` stanza so it can be controlled by the build?","created_at":"2018-08-12T12:25:07Z","updated_at":"2018-08-12T12:35:13Z","html_url":"https://github.com/nmichaels/smear/pull/1#discussion_r209453372","pull_request_url":"https://api.github.com/repos/nmichaels/smear/pulls/1","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/nmichaels/smear/pulls/comments/209453372"},"html":{"href":"https://github.com/nmichaels/smear/pull/1#discussion_r209453372"},"pull_request":{"href":"https://api.github.com/repos/nmichaels/smear/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/nmichaels/smear/pulls/1","id":207791238,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA3NzkxMjM4","html_url":"https://github.com/nmichaels/smear/pull/1","diff_url":"https://github.com/nmichaels/smear/pull/1.diff","patch_url":"https://github.com/nmichaels/smear/pull/1.patch","issue_url":"https://api.github.com/repos/nmichaels/smear/issues/1","number":1,"state":"open","locked":false,"title":"Cancellation","user":{"login":"nmichaels","id":265945,"node_id":"MDQ6VXNlcjI2NTk0NQ==","avatar_url":"https://avatars1.githubusercontent.com/u/265945?v=4","gravatar_id":"","url":"https://api.github.com/users/nmichaels","html_url":"https://github.com/nmichaels","followers_url":"https://api.github.com/users/nmichaels/followers","following_url":"https://api.github.com/users/nmichaels/following{/other_user}","gists_url":"https://api.github.com/users/nmichaels/gists{/gist_id}","starred_url":"https://api.github.com/users/nmichaels/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nmichaels/subscriptions","organizations_url":"https://api.github.com/users/nmichaels/orgs","repos_url":"https://api.github.com/users/nmichaels/repos","events_url":"https://api.github.com/users/nmichaels/events{/privacy}","received_events_url":"https://api.github.com/users/nmichaels/received_events","type":"User","site_admin":false},"body":"Adds timed event sending and cancellation. This uses a priority queue for all events, which could get inefficient with large queues. In the future we may want to separate out timed events and events that are scheduled for delivery, and add a cancellation mechanism that works for both.\r\n\r\nThis is simpler though, and since large queue sizes are unusual it's good enough too.","created_at":"2018-08-11T20:28:50Z","updated_at":"2018-08-12T12:35:13Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6406cd6a66139e5cbfcd19cf9f239167f1cea0bf","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/nmichaels/smear/pulls/1/commits","review_comments_url":"https://api.github.com/repos/nmichaels/smear/pulls/1/comments","review_comment_url":"https://api.github.com/repos/nmichaels/smear/pulls/comments{/number}","comments_url":"https://api.github.com/repos/nmichaels/smear/issues/1/comments","statuses_url":"https://api.github.com/repos/nmichaels/smear/statuses/88d8c6e715897f3438be1aace8b1ec8f266137a7","head":{"label":"nmichaels:cancellation","ref":"cancellation","sha":"88d8c6e715897f3438be1aace8b1ec8f266137a7","user":{"login":"nmichaels","id":265945,"node_id":"MDQ6VXNlcjI2NTk0NQ==","avatar_url":"https://avatars1.githubusercontent.com/u/265945?v=4","gravatar_id":"","url":"https://api.github.com/users/nmichaels","html_url":"https://github.com/nmichaels","followers_url":"https://api.github.com/users/nmichaels/followers","following_url":"https://api.github.com/users/nmichaels/following{/other_user}","gists_url":"https://api.github.com/users/nmichaels/gists{/gist_id}","starred_url":"https://api.github.com/users/nmichaels/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nmichaels/subscriptions","organizations_url":"https://api.github.com/users/nmichaels/orgs","repos_url":"https://api.github.com/users/nmichaels/repos","events_url":"https://api.github.com/users/nmichaels/events{/privacy}","received_events_url":"https://api.github.com/users/nmichaels/received_events","type":"User","site_admin":false},"repo":{"id":119310101,"node_id":"MDEwOlJlcG9zaXRvcnkxMTkzMTAxMDE=","name":"smear","full_name":"nmichaels/smear","owner":{"login":"nmichaels","id":265945,"node_id":"MDQ6VXNlcjI2NTk0NQ==","avatar_url":"https://avatars1.githubusercontent.com/u/265945?v=4","gravatar_id":"","url":"https://api.github.com/users/nmichaels","html_url":"https://github.com/nmichaels","followers_url":"https://api.github.com/users/nmichaels/followers","following_url":"https://api.github.com/users/nmichaels/following{/other_user}","gists_url":"https://api.github.com/users/nmichaels/gists{/gist_id}","starred_url":"https://api.github.com/users/nmichaels/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nmichaels/subscriptions","organizations_url":"https://api.github.com/users/nmichaels/orgs","repos_url":"https://api.github.com/users/nmichaels/repos","events_url":"https://api.github.com/users/nmichaels/events{/privacy}","received_events_url":"https://api.github.com/users/nmichaels/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nmichaels/smear","description":"Smudge runtime environment","fork":false,"url":"https://api.github.com/repos/nmichaels/smear","forks_url":"https://api.github.com/repos/nmichaels/smear/forks","keys_url":"https://api.github.com/repos/nmichaels/smear/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nmichaels/smear/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nmichaels/smear/teams","hooks_url":"https://api.github.com/repos/nmichaels/smear/hooks","issue_events_url":"https://api.github.com/repos/nmichaels/smear/issues/events{/number}","events_url":"https://api.github.com/repos/nmichaels/smear/events","assignees_url":"https://api.github.com/repos/nmichaels/smear/assignees{/user}","branches_url":"https://api.github.com/repos/nmichaels/smear/branches{/branch}","tags_url":"https://api.github.com/repos/nmichaels/smear/tags","blobs_url":"https://api.github.com/repos/nmichaels/smear/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nmichaels/smear/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nmichaels/smear/git/refs{/sha}","trees_url":"https://api.github.com/repos/nmichaels/smear/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nmichaels/smear/statuses/{sha}","languages_url":"https://api.github.com/repos/nmichaels/smear/languages","stargazers_url":"https://api.github.com/repos/nmichaels/smear/stargazers","contributors_url":"https://api.github.com/repos/nmichaels/smear/contributors","subscribers_url":"https://api.github.com/repos/nmichaels/smear/subscribers","subscription_url":"https://api.github.com/repos/nmichaels/smear/subscription","commits_url":"https://api.github.com/repos/nmichaels/smear/commits{/sha}","git_commits_url":"https://api.github.com/repos/nmichaels/smear/git/commits{/sha}","comments_url":"https://api.github.com/repos/nmichaels/smear/comments{/number}","issue_comment_url":"https://api.github.com/repos/nmichaels/smear/issues/comments{/number}","contents_url":"https://api.github.com/repos/nmichaels/smear/contents/{+path}","compare_url":"https://api.github.com/repos/nmichaels/smear/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nmichaels/smear/merges","archive_url":"https://api.github.com/repos/nmichaels/smear/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nmichaels/smear/downloads","issues_url":"https://api.github.com/repos/nmichaels/smear/issues{/number}","pulls_url":"https://api.github.com/repos/nmichaels/smear/pulls{/number}","milestones_url":"https://api.github.com/repos/nmichaels/smear/milestones{/number}","notifications_url":"https://api.github.com/repos/nmichaels/smear/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nmichaels/smear/labels{/name}","releases_url":"https://api.github.com/repos/nmichaels/smear/releases{/id}","deployments_url":"https://api.github.com/repos/nmichaels/smear/deployments","created_at":"2018-01-29T00:08:35Z","updated_at":"2018-08-11T21:59:41Z","pushed_at":"2018-08-11T21:59:39Z","git_url":"git://github.com/nmichaels/smear.git","ssh_url":"git@github.com:nmichaels/smear.git","clone_url":"https://github.com/nmichaels/smear.git","svn_url":"https://github.com/nmichaels/smear","homepage":null,"size":115,"stargazers_count":1,"watchers_count":1,"language":"C","has_issues":true,"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":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause","node_id":"MDc6TGljZW5zZTU="},"forks":0,"open_issues":1,"watchers":1,"default_branch":"master"}},"base":{"label":"nmichaels:master","ref":"master","sha":"7acb3e3144965df63c66e98ceed9dc3ae920876e","user":{"login":"nmichaels","id":265945,"node_id":"MDQ6VXNlcjI2NTk0NQ==","avatar_url":"https://avatars1.githubusercontent.com/u/265945?v=4","gravatar_id":"","url":"https://api.github.com/users/nmichaels","html_url":"https://github.com/nmichaels","followers_url":"https://api.github.com/users/nmichaels/followers","following_url":"https://api.github.com/users/nmichaels/following{/other_user}","gists_url":"https://api.github.com/users/nmichaels/gists{/gist_id}","starred_url":"https://api.github.com/users/nmichaels/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nmichaels/subscriptions","organizations_url":"https://api.github.com/users/nmichaels/orgs","repos_url":"https://api.github.com/users/nmichaels/repos","events_url":"https://api.github.com/users/nmichaels/events{/privacy}","received_events_url":"https://api.github.com/users/nmichaels/received_events","type":"User","site_admin":false},"repo":{"id":119310101,"node_id":"MDEwOlJlcG9zaXRvcnkxMTkzMTAxMDE=","name":"smear","full_name":"nmichaels/smear","owner":{"login":"nmichaels","id":265945,"node_id":"MDQ6VXNlcjI2NTk0NQ==","avatar_url":"https://avatars1.githubusercontent.com/u/265945?v=4","gravatar_id":"","url":"https://api.github.com/users/nmichaels","html_url":"https://github.com/nmichaels","followers_url":"https://api.github.com/users/nmichaels/followers","following_url":"https://api.github.com/users/nmichaels/following{/other_user}","gists_url":"https://api.github.com/users/nmichaels/gists{/gist_id}","starred_url":"https://api.github.com/users/nmichaels/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nmichaels/subscriptions","organizations_url":"https://api.github.com/users/nmichaels/orgs","repos_url":"https://api.github.com/users/nmichaels/repos","events_url":"https://api.github.com/users/nmichaels/events{/privacy}","received_events_url":"https://api.github.com/users/nmichaels/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nmichaels/smear","description":"Smudge runtime environment","fork":false,"url":"https://api.github.com/repos/nmichaels/smear","forks_url":"https://api.github.com/repos/nmichaels/smear/forks","keys_url":"https://api.github.com/repos/nmichaels/smear/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nmichaels/smear/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nmichaels/smear/teams","hooks_url":"https://api.github.com/repos/nmichaels/smear/hooks","issue_events_url":"https://api.github.com/repos/nmichaels/smear/issues/events{/number}","events_url":"https://api.github.com/repos/nmichaels/smear/events","assignees_url":"https://api.github.com/repos/nmichaels/smear/assignees{/user}","branches_url":"https://api.github.com/repos/nmichaels/smear/branches{/branch}","tags_url":"https://api.github.com/repos/nmichaels/smear/tags","blobs_url":"https://api.github.com/repos/nmichaels/smear/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nmichaels/smear/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nmichaels/smear/git/refs{/sha}","trees_url":"https://api.github.com/repos/nmichaels/smear/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nmichaels/smear/statuses/{sha}","languages_url":"https://api.github.com/repos/nmichaels/smear/languages","stargazers_url":"https://api.github.com/repos/nmichaels/smear/stargazers","contributors_url":"https://api.github.com/repos/nmichaels/smear/contributors","subscribers_url":"https://api.github.com/repos/nmichaels/smear/subscribers","subscription_url":"https://api.github.com/repos/nmichaels/smear/subscription","commits_url":"https://api.github.com/repos/nmichaels/smear/commits{/sha}","git_commits_url":"https://api.github.com/repos/nmichaels/smear/git/commits{/sha}","comments_url":"https://api.github.com/repos/nmichaels/smear/comments{/number}","issue_comment_url":"https://api.github.com/repos/nmichaels/smear/issues/comments{/number}","contents_url":"https://api.github.com/repos/nmichaels/smear/contents/{+path}","compare_url":"https://api.github.com/repos/nmichaels/smear/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nmichaels/smear/merges","archive_url":"https://api.github.com/repos/nmichaels/smear/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nmichaels/smear/downloads","issues_url":"https://api.github.com/repos/nmichaels/smear/issues{/number}","pulls_url":"https://api.github.com/repos/nmichaels/smear/pulls{/number}","milestones_url":"https://api.github.com/repos/nmichaels/smear/milestones{/number}","notifications_url":"https://api.github.com/repos/nmichaels/smear/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nmichaels/smear/labels{/name}","releases_url":"https://api.github.com/repos/nmichaels/smear/releases{/id}","deployments_url":"https://api.github.com/repos/nmichaels/smear/deployments","created_at":"2018-01-29T00:08:35Z","updated_at":"2018-08-11T21:59:41Z","pushed_at":"2018-08-11T21:59:39Z","git_url":"git://github.com/nmichaels/smear.git","ssh_url":"git@github.com:nmichaels/smear.git","clone_url":"https://github.com/nmichaels/smear.git","svn_url":"https://github.com/nmichaels/smear","homepage":null,"size":115,"stargazers_count":1,"watchers_count":1,"language":"C","has_issues":true,"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":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause","node_id":"MDc6TGljZW5zZTU="},"forks":0,"open_issues":1,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/nmichaels/smear/pulls/1"},"html":{"href":"https://github.com/nmichaels/smear/pull/1"},"issue":{"href":"https://api.github.com/repos/nmichaels/smear/issues/1"},"comments":{"href":"https://api.github.com/repos/nmichaels/smear/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/nmichaels/smear/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/nmichaels/smear/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/nmichaels/smear/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/nmichaels/smear/statuses/88d8c6e715897f3438be1aace8b1ec8f266137a7"}},"author_association":"OWNER"}}
{"actor":{"display_login":"natebragg"}}