{"action":"created","comment":{"url":"https://api.github.com/repos/PBSPro/pbspro/pulls/comments/79709500","id":79709500,"diff_hunk":"@@ -129,6 +129,13 @@ static char\tprocfs[] = \"/proc\";\n static DIR\t*pdir = NULL;\n static int\tpagesize;\n static long\thz;\n+\n+/* convert between jiffies and seconds */\n+#define\tJTOS(x)\t(((x) + (hz/2)) / hz)","path":"src/resmom/linux/mom_mach.c","position":64,"original_position":64,"commit_id":"ececb56c8cf003e639c474f8d97375b3039ed76b","original_commit_id":"ececb56c8cf003e639c474f8d97375b3039ed76b","user":{"login":"altair4","id":19158651,"avatar_url":"https://avatars.githubusercontent.com/u/19158651?v=3","gravatar_id":"","url":"https://api.github.com/users/altair4","html_url":"https://github.com/altair4","followers_url":"https://api.github.com/users/altair4/followers","following_url":"https://api.github.com/users/altair4/following{/other_user}","gists_url":"https://api.github.com/users/altair4/gists{/gist_id}","starred_url":"https://api.github.com/users/altair4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/altair4/subscriptions","organizations_url":"https://api.github.com/users/altair4/orgs","repos_url":"https://api.github.com/users/altair4/repos","events_url":"https://api.github.com/users/altair4/events{/privacy}","received_events_url":"https://api.github.com/users/altair4/received_events","type":"User","site_admin":false},"body":"Here's what the C99 standard (section 6.7.8, Initialization) says about static initializations:\r\n\r\nIf an object that has automatic storage duration is not initialized explicitly, its value is\r\nindeterminate. If an object that has static storage duration is not initialized explicitly,\r\nthen:\r\n- if it has pointer type, it is initialized to a null pointer;\r\n- if it has arithmetic type, it is initialized to (positive or unsigned) zero;\r\n- if it is an aggregate, every member is initialized (recursively) according to these rules;\r\n- if it is a union, the first named member is initialized (recursively) according to these\r\nrules.","created_at":"2016-09-20T20:52:28Z","updated_at":"2016-09-20T20:52:28Z","html_url":"https://github.com/PBSPro/pbspro/pull/154#discussion_r79709500","pull_request_url":"https://api.github.com/repos/PBSPro/pbspro/pulls/154","_links":{"self":{"href":"https://api.github.com/repos/PBSPro/pbspro/pulls/comments/79709500"},"html":{"href":"https://github.com/PBSPro/pbspro/pull/154#discussion_r79709500"},"pull_request":{"href":"https://api.github.com/repos/PBSPro/pbspro/pulls/154"}}},"pull_request":{"url":"https://api.github.com/repos/PBSPro/pbspro/pulls/154","id":84203991,"html_url":"https://github.com/PBSPro/pbspro/pull/154","diff_url":"https://github.com/PBSPro/pbspro/pull/154.diff","patch_url":"https://github.com/PBSPro/pbspro/pull/154.patch","issue_url":"https://api.github.com/repos/PBSPro/pbspro/issues/154","number":154,"state":"open","locked":false,"title":"PP-349:  changes to the reading of /proc/<PID>/stat fields","user":{"login":"altair4","id":19158651,"avatar_url":"https://avatars.githubusercontent.com/u/19158651?v=3","gravatar_id":"","url":"https://api.github.com/users/altair4","html_url":"https://github.com/altair4","followers_url":"https://api.github.com/users/altair4/followers","following_url":"https://api.github.com/users/altair4/following{/other_user}","gists_url":"https://api.github.com/users/altair4/gists{/gist_id}","starred_url":"https://api.github.com/users/altair4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/altair4/subscriptions","organizations_url":"https://api.github.com/users/altair4/orgs","repos_url":"https://api.github.com/users/altair4/repos","events_url":"https://api.github.com/users/altair4/events{/privacy}","received_events_url":"https://api.github.com/users/altair4/received_events","type":"User","site_admin":false},"body":"<!--- Please review your changes in preview mode -->\r\n<!--- Provide a general summary of your changes in the Title above -->\r\n\r\n#### PP-349\r\n<!--- Replace XXXX below (2 places) with the actual JIRA id -->\r\n* **[PP-349](https://pbspro.atlassian.net/browse/PP-349)**\r\n\r\n#### Problem description\r\n* Changes that attempt to avoid undiagnosed /proc/stat-related pbs_mom crashes\r\n\r\n#### Cause / Analysis\r\n* The cause of these crashes is unknown but speculated to be related to reading some /proc/<PID>/stat fields\r\n\r\n#### Solution description\r\n* This is a speculative change motivated by the hypothesis that reading certain fields from the /proc/<PID>/stat file may be the cause of some mysterious, occasionally seen crashes. In an effort to at least attempt to verify the speculation\r\n* We now read no fields beyond those that we consume (note, however, that reading of /proc/<pid>/stat uses stdio interfaces, so if merely reading some fields is the cause of the core dumps, we are still exposed)\r\n* The format string is dynamically generated to allow us to continue support of Linux 2.6 systems before 2.6.22 (where the flags field changed format)\r\n\r\n\r\n\r\n#### Checklist:\r\n<!--- Use the preview button to see the checkboxes/links properly. -->\r\n<!--- Go over the following points, and put an `x` (without spaces around it) in the boxes that apply. -->\r\n<!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->\r\n- [x] I have joined the **[pbspro community forum](http://community.pbspro.org/)**.\r\n- [x] My pull request contains a **single, signed** commit. See **[setting up gpg signature](https://pbspro.atlassian.net/wiki/display/DG/Signing+Your+Git+Commits)**.\r\n- [x] My code follows the **[coding style](https://pbspro.atlassian.net/wiki/display/DG/Coding+Standards)** of this project.\r\n- [ ] My change requires project documentation. See **[required documentation checklist](https://pbspro.atlassian.net/wiki/display/DG/Checklist+for+Developing+Features+and+Bug+Fixes)** for details.\r\n- [ ] I have added documentation in the **[project documentation area](https://pbspro.atlassian.net/wiki/display/PD)**.\r\n- [ ] I have added new **PTL test(s) to my commit**. (See **[using PTL for testing](https://pbspro.atlassian.net/wiki/display/DG/Using+PTL+for+Testing)**) *(or)*\r\n- [x] I have added  **manual test(s) to the Jira ticket and explained why PTL is not appropriate** for this case.\r\n- [x] All new and existing automated tests have passed. (See **[running automated PTL tests](https://pbspro.atlassian.net/wiki/display/DG/PTL+Quick+Start+Guide)**).\r\n- [ ] I have attached **test logs to the Jira ticket** as evidence of testing/verification.\r\n\r\n\r\n__***For further information please visit the [Developer Guide Home](https://pbspro.atlassian.net/wiki/display/DG/Developer+Guide+Home).***__\r\n","created_at":"2016-09-06T21:59:54Z","updated_at":"2016-09-20T20:52:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"36250341d3c330aae500e25ae9c85083a41c1546","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/PBSPro/pbspro/pulls/154/commits","review_comments_url":"https://api.github.com/repos/PBSPro/pbspro/pulls/154/comments","review_comment_url":"https://api.github.com/repos/PBSPro/pbspro/pulls/comments{/number}","comments_url":"https://api.github.com/repos/PBSPro/pbspro/issues/154/comments","statuses_url":"https://api.github.com/repos/PBSPro/pbspro/statuses/ececb56c8cf003e639c474f8d97375b3039ed76b","head":{"label":"altair4:pp-349","ref":"pp-349","sha":"ececb56c8cf003e639c474f8d97375b3039ed76b","user":{"login":"altair4","id":19158651,"avatar_url":"https://avatars.githubusercontent.com/u/19158651?v=3","gravatar_id":"","url":"https://api.github.com/users/altair4","html_url":"https://github.com/altair4","followers_url":"https://api.github.com/users/altair4/followers","following_url":"https://api.github.com/users/altair4/following{/other_user}","gists_url":"https://api.github.com/users/altair4/gists{/gist_id}","starred_url":"https://api.github.com/users/altair4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/altair4/subscriptions","organizations_url":"https://api.github.com/users/altair4/orgs","repos_url":"https://api.github.com/users/altair4/repos","events_url":"https://api.github.com/users/altair4/events{/privacy}","received_events_url":"https://api.github.com/users/altair4/received_events","type":"User","site_admin":false},"repo":{"id":64257449,"name":"pbspro","full_name":"altair4/pbspro","owner":{"login":"altair4","id":19158651,"avatar_url":"https://avatars.githubusercontent.com/u/19158651?v=3","gravatar_id":"","url":"https://api.github.com/users/altair4","html_url":"https://github.com/altair4","followers_url":"https://api.github.com/users/altair4/followers","following_url":"https://api.github.com/users/altair4/following{/other_user}","gists_url":"https://api.github.com/users/altair4/gists{/gist_id}","starred_url":"https://api.github.com/users/altair4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/altair4/subscriptions","organizations_url":"https://api.github.com/users/altair4/orgs","repos_url":"https://api.github.com/users/altair4/repos","events_url":"https://api.github.com/users/altair4/events{/privacy}","received_events_url":"https://api.github.com/users/altair4/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/altair4/pbspro","description":"An HPC workload manager and job scheduler for desktops, clusters, and clouds.","fork":true,"url":"https://api.github.com/repos/altair4/pbspro","forks_url":"https://api.github.com/repos/altair4/pbspro/forks","keys_url":"https://api.github.com/repos/altair4/pbspro/keys{/key_id}","collaborators_url":"https://api.github.com/repos/altair4/pbspro/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/altair4/pbspro/teams","hooks_url":"https://api.github.com/repos/altair4/pbspro/hooks","issue_events_url":"https://api.github.com/repos/altair4/pbspro/issues/events{/number}","events_url":"https://api.github.com/repos/altair4/pbspro/events","assignees_url":"https://api.github.com/repos/altair4/pbspro/assignees{/user}","branches_url":"https://api.github.com/repos/altair4/pbspro/branches{/branch}","tags_url":"https://api.github.com/repos/altair4/pbspro/tags","blobs_url":"https://api.github.com/repos/altair4/pbspro/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/altair4/pbspro/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/altair4/pbspro/git/refs{/sha}","trees_url":"https://api.github.com/repos/altair4/pbspro/git/trees{/sha}","statuses_url":"https://api.github.com/repos/altair4/pbspro/statuses/{sha}","languages_url":"https://api.github.com/repos/altair4/pbspro/languages","stargazers_url":"https://api.github.com/repos/altair4/pbspro/stargazers","contributors_url":"https://api.github.com/repos/altair4/pbspro/contributors","subscribers_url":"https://api.github.com/repos/altair4/pbspro/subscribers","subscription_url":"https://api.github.com/repos/altair4/pbspro/subscription","commits_url":"https://api.github.com/repos/altair4/pbspro/commits{/sha}","git_commits_url":"https://api.github.com/repos/altair4/pbspro/git/commits{/sha}","comments_url":"https://api.github.com/repos/altair4/pbspro/comments{/number}","issue_comment_url":"https://api.github.com/repos/altair4/pbspro/issues/comments{/number}","contents_url":"https://api.github.com/repos/altair4/pbspro/contents/{+path}","compare_url":"https://api.github.com/repos/altair4/pbspro/compare/{base}...{head}","merges_url":"https://api.github.com/repos/altair4/pbspro/merges","archive_url":"https://api.github.com/repos/altair4/pbspro/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/altair4/pbspro/downloads","issues_url":"https://api.github.com/repos/altair4/pbspro/issues{/number}","pulls_url":"https://api.github.com/repos/altair4/pbspro/pulls{/number}","milestones_url":"https://api.github.com/repos/altair4/pbspro/milestones{/number}","notifications_url":"https://api.github.com/repos/altair4/pbspro/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/altair4/pbspro/labels{/name}","releases_url":"https://api.github.com/repos/altair4/pbspro/releases{/id}","deployments_url":"https://api.github.com/repos/altair4/pbspro/deployments","created_at":"2016-07-26T21:55:55Z","updated_at":"2016-07-26T21:56:01Z","pushed_at":"2016-08-30T18:17:24Z","git_url":"git://github.com/altair4/pbspro.git","ssh_url":"git@github.com:altair4/pbspro.git","clone_url":"https://github.com/altair4/pbspro.git","svn_url":"https://github.com/altair4/pbspro","homepage":"www.pbspro.org","size":5323,"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":"PBSPro:master","ref":"master","sha":"de5815e267f8ab553b0940cb8ff683d6deed0ad1","user":{"login":"PBSPro","id":19280436,"avatar_url":"https://avatars.githubusercontent.com/u/19280436?v=3","gravatar_id":"","url":"https://api.github.com/users/PBSPro","html_url":"https://github.com/PBSPro","followers_url":"https://api.github.com/users/PBSPro/followers","following_url":"https://api.github.com/users/PBSPro/following{/other_user}","gists_url":"https://api.github.com/users/PBSPro/gists{/gist_id}","starred_url":"https://api.github.com/users/PBSPro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PBSPro/subscriptions","organizations_url":"https://api.github.com/users/PBSPro/orgs","repos_url":"https://api.github.com/users/PBSPro/repos","events_url":"https://api.github.com/users/PBSPro/events{/privacy}","received_events_url":"https://api.github.com/users/PBSPro/received_events","type":"Organization","site_admin":false},"repo":{"id":59082072,"name":"pbspro","full_name":"PBSPro/pbspro","owner":{"login":"PBSPro","id":19280436,"avatar_url":"https://avatars.githubusercontent.com/u/19280436?v=3","gravatar_id":"","url":"https://api.github.com/users/PBSPro","html_url":"https://github.com/PBSPro","followers_url":"https://api.github.com/users/PBSPro/followers","following_url":"https://api.github.com/users/PBSPro/following{/other_user}","gists_url":"https://api.github.com/users/PBSPro/gists{/gist_id}","starred_url":"https://api.github.com/users/PBSPro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PBSPro/subscriptions","organizations_url":"https://api.github.com/users/PBSPro/orgs","repos_url":"https://api.github.com/users/PBSPro/repos","events_url":"https://api.github.com/users/PBSPro/events{/privacy}","received_events_url":"https://api.github.com/users/PBSPro/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/PBSPro/pbspro","description":"An HPC workload manager and job scheduler for desktops, clusters, and clouds.","fork":false,"url":"https://api.github.com/repos/PBSPro/pbspro","forks_url":"https://api.github.com/repos/PBSPro/pbspro/forks","keys_url":"https://api.github.com/repos/PBSPro/pbspro/keys{/key_id}","collaborators_url":"https://api.github.com/repos/PBSPro/pbspro/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/PBSPro/pbspro/teams","hooks_url":"https://api.github.com/repos/PBSPro/pbspro/hooks","issue_events_url":"https://api.github.com/repos/PBSPro/pbspro/issues/events{/number}","events_url":"https://api.github.com/repos/PBSPro/pbspro/events","assignees_url":"https://api.github.com/repos/PBSPro/pbspro/assignees{/user}","branches_url":"https://api.github.com/repos/PBSPro/pbspro/branches{/branch}","tags_url":"https://api.github.com/repos/PBSPro/pbspro/tags","blobs_url":"https://api.github.com/repos/PBSPro/pbspro/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/PBSPro/pbspro/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/PBSPro/pbspro/git/refs{/sha}","trees_url":"https://api.github.com/repos/PBSPro/pbspro/git/trees{/sha}","statuses_url":"https://api.github.com/repos/PBSPro/pbspro/statuses/{sha}","languages_url":"https://api.github.com/repos/PBSPro/pbspro/languages","stargazers_url":"https://api.github.com/repos/PBSPro/pbspro/stargazers","contributors_url":"https://api.github.com/repos/PBSPro/pbspro/contributors","subscribers_url":"https://api.github.com/repos/PBSPro/pbspro/subscribers","subscription_url":"https://api.github.com/repos/PBSPro/pbspro/subscription","commits_url":"https://api.github.com/repos/PBSPro/pbspro/commits{/sha}","git_commits_url":"https://api.github.com/repos/PBSPro/pbspro/git/commits{/sha}","comments_url":"https://api.github.com/repos/PBSPro/pbspro/comments{/number}","issue_comment_url":"https://api.github.com/repos/PBSPro/pbspro/issues/comments{/number}","contents_url":"https://api.github.com/repos/PBSPro/pbspro/contents/{+path}","compare_url":"https://api.github.com/repos/PBSPro/pbspro/compare/{base}...{head}","merges_url":"https://api.github.com/repos/PBSPro/pbspro/merges","archive_url":"https://api.github.com/repos/PBSPro/pbspro/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/PBSPro/pbspro/downloads","issues_url":"https://api.github.com/repos/PBSPro/pbspro/issues{/number}","pulls_url":"https://api.github.com/repos/PBSPro/pbspro/pulls{/number}","milestones_url":"https://api.github.com/repos/PBSPro/pbspro/milestones{/number}","notifications_url":"https://api.github.com/repos/PBSPro/pbspro/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/PBSPro/pbspro/labels{/name}","releases_url":"https://api.github.com/repos/PBSPro/pbspro/releases{/id}","deployments_url":"https://api.github.com/repos/PBSPro/pbspro/deployments","created_at":"2016-05-18T04:31:29Z","updated_at":"2016-09-16T04:13:11Z","pushed_at":"2016-09-20T15:43:34Z","git_url":"git://github.com/PBSPro/pbspro.git","ssh_url":"git@github.com:PBSPro/pbspro.git","clone_url":"https://github.com/PBSPro/pbspro.git","svn_url":"https://github.com/PBSPro/pbspro","homepage":"www.pbspro.org","size":6066,"stargazers_count":52,"watchers_count":52,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":54,"mirror_url":null,"open_issues_count":3,"forks":54,"open_issues":3,"watchers":52,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/PBSPro/pbspro/pulls/154"},"html":{"href":"https://github.com/PBSPro/pbspro/pull/154"},"issue":{"href":"https://api.github.com/repos/PBSPro/pbspro/issues/154"},"comments":{"href":"https://api.github.com/repos/PBSPro/pbspro/issues/154/comments"},"review_comments":{"href":"https://api.github.com/repos/PBSPro/pbspro/pulls/154/comments"},"review_comment":{"href":"https://api.github.com/repos/PBSPro/pbspro/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/PBSPro/pbspro/pulls/154/commits"},"statuses":{"href":"https://api.github.com/repos/PBSPro/pbspro/statuses/ececb56c8cf003e639c474f8d97375b3039ed76b"}}}}
{"actor":{"display_login":"altair4"}}