{"action":"created","comment":{"url":"https://api.github.com/repos/apache/trafficserver/pulls/comments/173213264","pull_request_review_id":102365235,"id":173213264,"diff_hunk":"@@ -70,30 +72,50 @@ readIntoBuffer(const char *file_path, const char *module_name, int *read_size_pt\n     return nullptr;\n   }\n \n-  if (file_info.st_size < 0) {\n+  file_size = file_info.st_size; // number of bytes in file\n+\n+  if (file_size < 0) {\n     Error(\"%s Can not get correct file size for %s file : %\" PRId64 \"\", module_name, file_path, (int64_t)file_info.st_size);\n     close(fd);\n     return nullptr;\n   }\n+\n+  ink_assert(file_size >= 0);\n+  ink_assert(file_size == file_info.st_size);","path":"lib/ts/MatcherUtils.cc","position":26,"original_position":26,"commit_id":"0b0025fb85f594a3031e3c44f9da5d6a880a7362","original_commit_id":"0b0025fb85f594a3031e3c44f9da5d6a880a7362","user":{"login":"bryancall","id":216749,"avatar_url":"https://avatars3.githubusercontent.com/u/216749?v=4","gravatar_id":"","url":"https://api.github.com/users/bryancall","html_url":"https://github.com/bryancall","followers_url":"https://api.github.com/users/bryancall/followers","following_url":"https://api.github.com/users/bryancall/following{/other_user}","gists_url":"https://api.github.com/users/bryancall/gists{/gist_id}","starred_url":"https://api.github.com/users/bryancall/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bryancall/subscriptions","organizations_url":"https://api.github.com/users/bryancall/orgs","repos_url":"https://api.github.com/users/bryancall/repos","events_url":"https://api.github.com/users/bryancall/events{/privacy}","received_events_url":"https://api.github.com/users/bryancall/received_events","type":"User","site_admin":false},"body":"This isn't necessary since you are doing an assignment right above.","created_at":"2018-03-08T16:31:51Z","updated_at":"2018-03-08T16:36:59Z","html_url":"https://github.com/apache/trafficserver/pull/3244#discussion_r173213264","pull_request_url":"https://api.github.com/repos/apache/trafficserver/pulls/3244","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/apache/trafficserver/pulls/comments/173213264"},"html":{"href":"https://github.com/apache/trafficserver/pull/3244#discussion_r173213264"},"pull_request":{"href":"https://api.github.com/repos/apache/trafficserver/pulls/3244"}}},"pull_request":{"url":"https://api.github.com/repos/apache/trafficserver/pulls/3244","id":173561778,"html_url":"https://github.com/apache/trafficserver/pull/3244","diff_url":"https://github.com/apache/trafficserver/pull/3244.diff","patch_url":"https://github.com/apache/trafficserver/pull/3244.patch","issue_url":"https://api.github.com/repos/apache/trafficserver/issues/3244","number":3244,"state":"open","locked":false,"title":"Loop over read for readIntoBuffer","user":{"login":"xf6wang","id":22967511,"avatar_url":"https://avatars1.githubusercontent.com/u/22967511?v=4","gravatar_id":"","url":"https://api.github.com/users/xf6wang","html_url":"https://github.com/xf6wang","followers_url":"https://api.github.com/users/xf6wang/followers","following_url":"https://api.github.com/users/xf6wang/following{/other_user}","gists_url":"https://api.github.com/users/xf6wang/gists{/gist_id}","starred_url":"https://api.github.com/users/xf6wang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xf6wang/subscriptions","organizations_url":"https://api.github.com/users/xf6wang/orgs","repos_url":"https://api.github.com/users/xf6wang/repos","events_url":"https://api.github.com/users/xf6wang/events{/privacy}","received_events_url":"https://api.github.com/users/xf6wang/received_events","type":"User","site_admin":false},"body":"Loop over the read to ensure that we have really read everything we can. \r\n\r\n@bryancall can you take a look?","created_at":"2018-03-07T20:15:34Z","updated_at":"2018-03-08T16:37:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0bec1556ec961944863009c47f17f007b7d5adf8","assignee":{"login":"xf6wang","id":22967511,"avatar_url":"https://avatars1.githubusercontent.com/u/22967511?v=4","gravatar_id":"","url":"https://api.github.com/users/xf6wang","html_url":"https://github.com/xf6wang","followers_url":"https://api.github.com/users/xf6wang/followers","following_url":"https://api.github.com/users/xf6wang/following{/other_user}","gists_url":"https://api.github.com/users/xf6wang/gists{/gist_id}","starred_url":"https://api.github.com/users/xf6wang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xf6wang/subscriptions","organizations_url":"https://api.github.com/users/xf6wang/orgs","repos_url":"https://api.github.com/users/xf6wang/repos","events_url":"https://api.github.com/users/xf6wang/events{/privacy}","received_events_url":"https://api.github.com/users/xf6wang/received_events","type":"User","site_admin":false},"assignees":[{"login":"xf6wang","id":22967511,"avatar_url":"https://avatars1.githubusercontent.com/u/22967511?v=4","gravatar_id":"","url":"https://api.github.com/users/xf6wang","html_url":"https://github.com/xf6wang","followers_url":"https://api.github.com/users/xf6wang/followers","following_url":"https://api.github.com/users/xf6wang/following{/other_user}","gists_url":"https://api.github.com/users/xf6wang/gists{/gist_id}","starred_url":"https://api.github.com/users/xf6wang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xf6wang/subscriptions","organizations_url":"https://api.github.com/users/xf6wang/orgs","repos_url":"https://api.github.com/users/xf6wang/repos","events_url":"https://api.github.com/users/xf6wang/events{/privacy}","received_events_url":"https://api.github.com/users/xf6wang/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":{"url":"https://api.github.com/repos/apache/trafficserver/milestones/6","html_url":"https://github.com/apache/trafficserver/milestone/6","labels_url":"https://api.github.com/repos/apache/trafficserver/milestones/6/labels","id":1763406,"number":6,"title":"8.0.0","description":"","creator":{"login":"zwoop","id":202131,"avatar_url":"https://avatars1.githubusercontent.com/u/202131?v=4","gravatar_id":"","url":"https://api.github.com/users/zwoop","html_url":"https://github.com/zwoop","followers_url":"https://api.github.com/users/zwoop/followers","following_url":"https://api.github.com/users/zwoop/following{/other_user}","gists_url":"https://api.github.com/users/zwoop/gists{/gist_id}","starred_url":"https://api.github.com/users/zwoop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zwoop/subscriptions","organizations_url":"https://api.github.com/users/zwoop/orgs","repos_url":"https://api.github.com/users/zwoop/repos","events_url":"https://api.github.com/users/zwoop/events{/privacy}","received_events_url":"https://api.github.com/users/zwoop/received_events","type":"User","site_admin":false},"open_issues":81,"closed_issues":913,"state":"open","created_at":"2016-05-12T22:13:34Z","updated_at":"2018-03-08T16:02:20Z","due_on":"2018-06-18T07:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/apache/trafficserver/pulls/3244/commits","review_comments_url":"https://api.github.com/repos/apache/trafficserver/pulls/3244/comments","review_comment_url":"https://api.github.com/repos/apache/trafficserver/pulls/comments{/number}","comments_url":"https://api.github.com/repos/apache/trafficserver/issues/3244/comments","statuses_url":"https://api.github.com/repos/apache/trafficserver/statuses/0b0025fb85f594a3031e3c44f9da5d6a880a7362","head":{"label":"xf6wang:readIntoBuffer","ref":"readIntoBuffer","sha":"0b0025fb85f594a3031e3c44f9da5d6a880a7362","user":{"login":"xf6wang","id":22967511,"avatar_url":"https://avatars1.githubusercontent.com/u/22967511?v=4","gravatar_id":"","url":"https://api.github.com/users/xf6wang","html_url":"https://github.com/xf6wang","followers_url":"https://api.github.com/users/xf6wang/followers","following_url":"https://api.github.com/users/xf6wang/following{/other_user}","gists_url":"https://api.github.com/users/xf6wang/gists{/gist_id}","starred_url":"https://api.github.com/users/xf6wang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xf6wang/subscriptions","organizations_url":"https://api.github.com/users/xf6wang/orgs","repos_url":"https://api.github.com/users/xf6wang/repos","events_url":"https://api.github.com/users/xf6wang/events{/privacy}","received_events_url":"https://api.github.com/users/xf6wang/received_events","type":"User","site_admin":false},"repo":{"id":118801755,"name":"trafficserver","full_name":"xf6wang/trafficserver","owner":{"login":"xf6wang","id":22967511,"avatar_url":"https://avatars1.githubusercontent.com/u/22967511?v=4","gravatar_id":"","url":"https://api.github.com/users/xf6wang","html_url":"https://github.com/xf6wang","followers_url":"https://api.github.com/users/xf6wang/followers","following_url":"https://api.github.com/users/xf6wang/following{/other_user}","gists_url":"https://api.github.com/users/xf6wang/gists{/gist_id}","starred_url":"https://api.github.com/users/xf6wang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xf6wang/subscriptions","organizations_url":"https://api.github.com/users/xf6wang/orgs","repos_url":"https://api.github.com/users/xf6wang/repos","events_url":"https://api.github.com/users/xf6wang/events{/privacy}","received_events_url":"https://api.github.com/users/xf6wang/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/xf6wang/trafficserver","description":"Mirror of Apache Traffic Server","fork":true,"url":"https://api.github.com/repos/xf6wang/trafficserver","forks_url":"https://api.github.com/repos/xf6wang/trafficserver/forks","keys_url":"https://api.github.com/repos/xf6wang/trafficserver/keys{/key_id}","collaborators_url":"https://api.github.com/repos/xf6wang/trafficserver/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/xf6wang/trafficserver/teams","hooks_url":"https://api.github.com/repos/xf6wang/trafficserver/hooks","issue_events_url":"https://api.github.com/repos/xf6wang/trafficserver/issues/events{/number}","events_url":"https://api.github.com/repos/xf6wang/trafficserver/events","assignees_url":"https://api.github.com/repos/xf6wang/trafficserver/assignees{/user}","branches_url":"https://api.github.com/repos/xf6wang/trafficserver/branches{/branch}","tags_url":"https://api.github.com/repos/xf6wang/trafficserver/tags","blobs_url":"https://api.github.com/repos/xf6wang/trafficserver/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/xf6wang/trafficserver/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/xf6wang/trafficserver/git/refs{/sha}","trees_url":"https://api.github.com/repos/xf6wang/trafficserver/git/trees{/sha}","statuses_url":"https://api.github.com/repos/xf6wang/trafficserver/statuses/{sha}","languages_url":"https://api.github.com/repos/xf6wang/trafficserver/languages","stargazers_url":"https://api.github.com/repos/xf6wang/trafficserver/stargazers","contributors_url":"https://api.github.com/repos/xf6wang/trafficserver/contributors","subscribers_url":"https://api.github.com/repos/xf6wang/trafficserver/subscribers","subscription_url":"https://api.github.com/repos/xf6wang/trafficserver/subscription","commits_url":"https://api.github.com/repos/xf6wang/trafficserver/commits{/sha}","git_commits_url":"https://api.github.com/repos/xf6wang/trafficserver/git/commits{/sha}","comments_url":"https://api.github.com/repos/xf6wang/trafficserver/comments{/number}","issue_comment_url":"https://api.github.com/repos/xf6wang/trafficserver/issues/comments{/number}","contents_url":"https://api.github.com/repos/xf6wang/trafficserver/contents/{+path}","compare_url":"https://api.github.com/repos/xf6wang/trafficserver/compare/{base}...{head}","merges_url":"https://api.github.com/repos/xf6wang/trafficserver/merges","archive_url":"https://api.github.com/repos/xf6wang/trafficserver/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/xf6wang/trafficserver/downloads","issues_url":"https://api.github.com/repos/xf6wang/trafficserver/issues{/number}","pulls_url":"https://api.github.com/repos/xf6wang/trafficserver/pulls{/number}","milestones_url":"https://api.github.com/repos/xf6wang/trafficserver/milestones{/number}","notifications_url":"https://api.github.com/repos/xf6wang/trafficserver/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/xf6wang/trafficserver/labels{/name}","releases_url":"https://api.github.com/repos/xf6wang/trafficserver/releases{/id}","deployments_url":"https://api.github.com/repos/xf6wang/trafficserver/deployments","created_at":"2018-01-24T17:59:51Z","updated_at":"2018-01-24T18:00:00Z","pushed_at":"2018-03-08T01:43:14Z","git_url":"git://github.com/xf6wang/trafficserver.git","ssh_url":"git@github.com:xf6wang/trafficserver.git","clone_url":"https://github.com/xf6wang/trafficserver.git","svn_url":"https://github.com/xf6wang/trafficserver","homepage":null,"size":80136,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"apache:master","ref":"master","sha":"3d4564835a21772c2c0202edee4fbe02f709525d","user":{"login":"apache","id":47359,"avatar_url":"https://avatars0.githubusercontent.com/u/47359?v=4","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"repo":{"id":356066,"name":"trafficserver","full_name":"apache/trafficserver","owner":{"login":"apache","id":47359,"avatar_url":"https://avatars0.githubusercontent.com/u/47359?v=4","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/apache/trafficserver","description":"Mirror of Apache Traffic Server","fork":false,"url":"https://api.github.com/repos/apache/trafficserver","forks_url":"https://api.github.com/repos/apache/trafficserver/forks","keys_url":"https://api.github.com/repos/apache/trafficserver/keys{/key_id}","collaborators_url":"https://api.github.com/repos/apache/trafficserver/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/apache/trafficserver/teams","hooks_url":"https://api.github.com/repos/apache/trafficserver/hooks","issue_events_url":"https://api.github.com/repos/apache/trafficserver/issues/events{/number}","events_url":"https://api.github.com/repos/apache/trafficserver/events","assignees_url":"https://api.github.com/repos/apache/trafficserver/assignees{/user}","branches_url":"https://api.github.com/repos/apache/trafficserver/branches{/branch}","tags_url":"https://api.github.com/repos/apache/trafficserver/tags","blobs_url":"https://api.github.com/repos/apache/trafficserver/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/apache/trafficserver/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/apache/trafficserver/git/refs{/sha}","trees_url":"https://api.github.com/repos/apache/trafficserver/git/trees{/sha}","statuses_url":"https://api.github.com/repos/apache/trafficserver/statuses/{sha}","languages_url":"https://api.github.com/repos/apache/trafficserver/languages","stargazers_url":"https://api.github.com/repos/apache/trafficserver/stargazers","contributors_url":"https://api.github.com/repos/apache/trafficserver/contributors","subscribers_url":"https://api.github.com/repos/apache/trafficserver/subscribers","subscription_url":"https://api.github.com/repos/apache/trafficserver/subscription","commits_url":"https://api.github.com/repos/apache/trafficserver/commits{/sha}","git_commits_url":"https://api.github.com/repos/apache/trafficserver/git/commits{/sha}","comments_url":"https://api.github.com/repos/apache/trafficserver/comments{/number}","issue_comment_url":"https://api.github.com/repos/apache/trafficserver/issues/comments{/number}","contents_url":"https://api.github.com/repos/apache/trafficserver/contents/{+path}","compare_url":"https://api.github.com/repos/apache/trafficserver/compare/{base}...{head}","merges_url":"https://api.github.com/repos/apache/trafficserver/merges","archive_url":"https://api.github.com/repos/apache/trafficserver/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/apache/trafficserver/downloads","issues_url":"https://api.github.com/repos/apache/trafficserver/issues{/number}","pulls_url":"https://api.github.com/repos/apache/trafficserver/pulls{/number}","milestones_url":"https://api.github.com/repos/apache/trafficserver/milestones{/number}","notifications_url":"https://api.github.com/repos/apache/trafficserver/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/apache/trafficserver/labels{/name}","releases_url":"https://api.github.com/repos/apache/trafficserver/releases{/id}","deployments_url":"https://api.github.com/repos/apache/trafficserver/deployments","created_at":"2009-10-31T08:00:10Z","updated_at":"2018-03-08T01:03:36Z","pushed_at":"2018-03-08T16:26:11Z","git_url":"git://github.com/apache/trafficserver.git","ssh_url":"git@github.com:apache/trafficserver.git","clone_url":"https://github.com/apache/trafficserver.git","svn_url":"https://github.com/apache/trafficserver","homepage":null,"size":80478,"stargazers_count":662,"watchers_count":662,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":496,"mirror_url":null,"archived":false,"open_issues_count":275,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":496,"open_issues":275,"watchers":662,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/apache/trafficserver/pulls/3244"},"html":{"href":"https://github.com/apache/trafficserver/pull/3244"},"issue":{"href":"https://api.github.com/repos/apache/trafficserver/issues/3244"},"comments":{"href":"https://api.github.com/repos/apache/trafficserver/issues/3244/comments"},"review_comments":{"href":"https://api.github.com/repos/apache/trafficserver/pulls/3244/comments"},"review_comment":{"href":"https://api.github.com/repos/apache/trafficserver/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/apache/trafficserver/pulls/3244/commits"},"statuses":{"href":"https://api.github.com/repos/apache/trafficserver/statuses/0b0025fb85f594a3031e3c44f9da5d6a880a7362"}},"author_association":"NONE"}}
{"actor":{"display_login":"bryancall"}}