{"action":"closed","number":6355,"pull_request":{"url":"https://api.github.com/repos/kripken/emscripten/pulls/6355","id":176266874,"html_url":"https://github.com/kripken/emscripten/pull/6355","diff_url":"https://github.com/kripken/emscripten/pull/6355.diff","patch_url":"https://github.com/kripken/emscripten/pull/6355.patch","issue_url":"https://api.github.com/repos/kripken/emscripten/issues/6355","number":6355,"state":"closed","locked":false,"title":"Fix some issues with static data in SIDE_MODULEs","user":{"login":"mdboom","id":38294,"avatar_url":"https://avatars3.githubusercontent.com/u/38294?v=4","gravatar_id":"","url":"https://api.github.com/users/mdboom","html_url":"https://github.com/mdboom","followers_url":"https://api.github.com/users/mdboom/followers","following_url":"https://api.github.com/users/mdboom/following{/other_user}","gists_url":"https://api.github.com/users/mdboom/gists{/gist_id}","starred_url":"https://api.github.com/users/mdboom/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mdboom/subscriptions","organizations_url":"https://api.github.com/users/mdboom/orgs","repos_url":"https://api.github.com/users/mdboom/repos","events_url":"https://api.github.com/users/mdboom/events{/privacy}","received_events_url":"https://api.github.com/users/mdboom/received_events","type":"User","site_admin":false},"body":"This fixes #6310, though my hunches about the root cause turned out to be wrong.\r\n\r\nThere are two fixes here:\r\n\r\n1) The static data in a module generally consists of content initialized with an array literal, followed by zeroinitialized content.  The latter was not getting zero-initialized when the static chunk is allocated.  Changing the `malloc` within `getMemory` to `calloc` seems to resolve this.\r\n\r\n2) Static memory chunks in side modules were not getting aligned correctly.  This seems to be due to a parentheses placement bug.  This seems to manifest when there are short (empty) strings in the last 8 bytes at the end of the zero-initialized area.","created_at":"2018-03-20T17:29:55Z","updated_at":"2018-03-29T19:54:08Z","closed_at":"2018-03-29T19:54:08Z","merged_at":"2018-03-29T19:54:08Z","merge_commit_sha":"71c46094f70bf90308d6a6923a80afa1c9604bba","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/kripken/emscripten/pulls/6355/commits","review_comments_url":"https://api.github.com/repos/kripken/emscripten/pulls/6355/comments","review_comment_url":"https://api.github.com/repos/kripken/emscripten/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kripken/emscripten/issues/6355/comments","statuses_url":"https://api.github.com/repos/kripken/emscripten/statuses/c270d0d5dd51d678da59ee63b09385c269a6b981","head":{"label":"mdboom:fix-align-static","ref":"fix-align-static","sha":"c270d0d5dd51d678da59ee63b09385c269a6b981","user":{"login":"mdboom","id":38294,"avatar_url":"https://avatars3.githubusercontent.com/u/38294?v=4","gravatar_id":"","url":"https://api.github.com/users/mdboom","html_url":"https://github.com/mdboom","followers_url":"https://api.github.com/users/mdboom/followers","following_url":"https://api.github.com/users/mdboom/following{/other_user}","gists_url":"https://api.github.com/users/mdboom/gists{/gist_id}","starred_url":"https://api.github.com/users/mdboom/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mdboom/subscriptions","organizations_url":"https://api.github.com/users/mdboom/orgs","repos_url":"https://api.github.com/users/mdboom/repos","events_url":"https://api.github.com/users/mdboom/events{/privacy}","received_events_url":"https://api.github.com/users/mdboom/received_events","type":"User","site_admin":false},"repo":{"id":124267151,"name":"emscripten","full_name":"mdboom/emscripten","owner":{"login":"mdboom","id":38294,"avatar_url":"https://avatars3.githubusercontent.com/u/38294?v=4","gravatar_id":"","url":"https://api.github.com/users/mdboom","html_url":"https://github.com/mdboom","followers_url":"https://api.github.com/users/mdboom/followers","following_url":"https://api.github.com/users/mdboom/following{/other_user}","gists_url":"https://api.github.com/users/mdboom/gists{/gist_id}","starred_url":"https://api.github.com/users/mdboom/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mdboom/subscriptions","organizations_url":"https://api.github.com/users/mdboom/orgs","repos_url":"https://api.github.com/users/mdboom/repos","events_url":"https://api.github.com/users/mdboom/events{/privacy}","received_events_url":"https://api.github.com/users/mdboom/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mdboom/emscripten","description":"Emscripten: An LLVM-to-JavaScript Compiler","fork":true,"url":"https://api.github.com/repos/mdboom/emscripten","forks_url":"https://api.github.com/repos/mdboom/emscripten/forks","keys_url":"https://api.github.com/repos/mdboom/emscripten/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mdboom/emscripten/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mdboom/emscripten/teams","hooks_url":"https://api.github.com/repos/mdboom/emscripten/hooks","issue_events_url":"https://api.github.com/repos/mdboom/emscripten/issues/events{/number}","events_url":"https://api.github.com/repos/mdboom/emscripten/events","assignees_url":"https://api.github.com/repos/mdboom/emscripten/assignees{/user}","branches_url":"https://api.github.com/repos/mdboom/emscripten/branches{/branch}","tags_url":"https://api.github.com/repos/mdboom/emscripten/tags","blobs_url":"https://api.github.com/repos/mdboom/emscripten/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mdboom/emscripten/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mdboom/emscripten/git/refs{/sha}","trees_url":"https://api.github.com/repos/mdboom/emscripten/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mdboom/emscripten/statuses/{sha}","languages_url":"https://api.github.com/repos/mdboom/emscripten/languages","stargazers_url":"https://api.github.com/repos/mdboom/emscripten/stargazers","contributors_url":"https://api.github.com/repos/mdboom/emscripten/contributors","subscribers_url":"https://api.github.com/repos/mdboom/emscripten/subscribers","subscription_url":"https://api.github.com/repos/mdboom/emscripten/subscription","commits_url":"https://api.github.com/repos/mdboom/emscripten/commits{/sha}","git_commits_url":"https://api.github.com/repos/mdboom/emscripten/git/commits{/sha}","comments_url":"https://api.github.com/repos/mdboom/emscripten/comments{/number}","issue_comment_url":"https://api.github.com/repos/mdboom/emscripten/issues/comments{/number}","contents_url":"https://api.github.com/repos/mdboom/emscripten/contents/{+path}","compare_url":"https://api.github.com/repos/mdboom/emscripten/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mdboom/emscripten/merges","archive_url":"https://api.github.com/repos/mdboom/emscripten/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mdboom/emscripten/downloads","issues_url":"https://api.github.com/repos/mdboom/emscripten/issues{/number}","pulls_url":"https://api.github.com/repos/mdboom/emscripten/pulls{/number}","milestones_url":"https://api.github.com/repos/mdboom/emscripten/milestones{/number}","notifications_url":"https://api.github.com/repos/mdboom/emscripten/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mdboom/emscripten/labels{/name}","releases_url":"https://api.github.com/repos/mdboom/emscripten/releases{/id}","deployments_url":"https://api.github.com/repos/mdboom/emscripten/deployments","created_at":"2018-03-07T16:58:12Z","updated_at":"2018-03-07T16:58:34Z","pushed_at":"2018-03-29T15:29:15Z","git_url":"git://github.com/mdboom/emscripten.git","ssh_url":"git@github.com:mdboom/emscripten.git","clone_url":"https://github.com/mdboom/emscripten.git","svn_url":"https://github.com/mdboom/emscripten","homepage":"","size":158745,"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":"other","name":"Other","spdx_id":null,"url":null},"forks":0,"open_issues":0,"watchers":0,"default_branch":"incoming"}},"base":{"label":"kripken:incoming","ref":"incoming","sha":"f6d775c8abba2a7f5c0d73893cd6a3e18f041ff3","user":{"login":"kripken","id":173661,"avatar_url":"https://avatars0.githubusercontent.com/u/173661?v=4","gravatar_id":"","url":"https://api.github.com/users/kripken","html_url":"https://github.com/kripken","followers_url":"https://api.github.com/users/kripken/followers","following_url":"https://api.github.com/users/kripken/following{/other_user}","gists_url":"https://api.github.com/users/kripken/gists{/gist_id}","starred_url":"https://api.github.com/users/kripken/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kripken/subscriptions","organizations_url":"https://api.github.com/users/kripken/orgs","repos_url":"https://api.github.com/users/kripken/repos","events_url":"https://api.github.com/users/kripken/events{/privacy}","received_events_url":"https://api.github.com/users/kripken/received_events","type":"User","site_admin":false},"repo":{"id":1357796,"name":"emscripten","full_name":"kripken/emscripten","owner":{"login":"kripken","id":173661,"avatar_url":"https://avatars0.githubusercontent.com/u/173661?v=4","gravatar_id":"","url":"https://api.github.com/users/kripken","html_url":"https://github.com/kripken","followers_url":"https://api.github.com/users/kripken/followers","following_url":"https://api.github.com/users/kripken/following{/other_user}","gists_url":"https://api.github.com/users/kripken/gists{/gist_id}","starred_url":"https://api.github.com/users/kripken/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kripken/subscriptions","organizations_url":"https://api.github.com/users/kripken/orgs","repos_url":"https://api.github.com/users/kripken/repos","events_url":"https://api.github.com/users/kripken/events{/privacy}","received_events_url":"https://api.github.com/users/kripken/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kripken/emscripten","description":"Emscripten: An LLVM-to-JavaScript Compiler","fork":false,"url":"https://api.github.com/repos/kripken/emscripten","forks_url":"https://api.github.com/repos/kripken/emscripten/forks","keys_url":"https://api.github.com/repos/kripken/emscripten/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kripken/emscripten/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kripken/emscripten/teams","hooks_url":"https://api.github.com/repos/kripken/emscripten/hooks","issue_events_url":"https://api.github.com/repos/kripken/emscripten/issues/events{/number}","events_url":"https://api.github.com/repos/kripken/emscripten/events","assignees_url":"https://api.github.com/repos/kripken/emscripten/assignees{/user}","branches_url":"https://api.github.com/repos/kripken/emscripten/branches{/branch}","tags_url":"https://api.github.com/repos/kripken/emscripten/tags","blobs_url":"https://api.github.com/repos/kripken/emscripten/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kripken/emscripten/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kripken/emscripten/git/refs{/sha}","trees_url":"https://api.github.com/repos/kripken/emscripten/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kripken/emscripten/statuses/{sha}","languages_url":"https://api.github.com/repos/kripken/emscripten/languages","stargazers_url":"https://api.github.com/repos/kripken/emscripten/stargazers","contributors_url":"https://api.github.com/repos/kripken/emscripten/contributors","subscribers_url":"https://api.github.com/repos/kripken/emscripten/subscribers","subscription_url":"https://api.github.com/repos/kripken/emscripten/subscription","commits_url":"https://api.github.com/repos/kripken/emscripten/commits{/sha}","git_commits_url":"https://api.github.com/repos/kripken/emscripten/git/commits{/sha}","comments_url":"https://api.github.com/repos/kripken/emscripten/comments{/number}","issue_comment_url":"https://api.github.com/repos/kripken/emscripten/issues/comments{/number}","contents_url":"https://api.github.com/repos/kripken/emscripten/contents/{+path}","compare_url":"https://api.github.com/repos/kripken/emscripten/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kripken/emscripten/merges","archive_url":"https://api.github.com/repos/kripken/emscripten/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kripken/emscripten/downloads","issues_url":"https://api.github.com/repos/kripken/emscripten/issues{/number}","pulls_url":"https://api.github.com/repos/kripken/emscripten/pulls{/number}","milestones_url":"https://api.github.com/repos/kripken/emscripten/milestones{/number}","notifications_url":"https://api.github.com/repos/kripken/emscripten/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kripken/emscripten/labels{/name}","releases_url":"https://api.github.com/repos/kripken/emscripten/releases{/id}","deployments_url":"https://api.github.com/repos/kripken/emscripten/deployments","created_at":"2011-02-12T05:23:30Z","updated_at":"2018-03-29T19:54:35Z","pushed_at":"2018-03-29T19:55:59Z","git_url":"git://github.com/kripken/emscripten.git","ssh_url":"git@github.com:kripken/emscripten.git","clone_url":"https://github.com/kripken/emscripten.git","svn_url":"https://github.com/kripken/emscripten","homepage":"","size":159250,"stargazers_count":14337,"watchers_count":14337,"language":"C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1703,"mirror_url":null,"archived":false,"open_issues_count":1425,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":1703,"open_issues":1425,"watchers":14337,"default_branch":"incoming"}},"_links":{"self":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/6355"},"html":{"href":"https://github.com/kripken/emscripten/pull/6355"},"issue":{"href":"https://api.github.com/repos/kripken/emscripten/issues/6355"},"comments":{"href":"https://api.github.com/repos/kripken/emscripten/issues/6355/comments"},"review_comments":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/6355/comments"},"review_comment":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kripken/emscripten/pulls/6355/commits"},"statuses":{"href":"https://api.github.com/repos/kripken/emscripten/statuses/c270d0d5dd51d678da59ee63b09385c269a6b981"}},"author_association":"CONTRIBUTOR","merged":true,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":{"login":"kripken","id":173661,"avatar_url":"https://avatars0.githubusercontent.com/u/173661?v=4","gravatar_id":"","url":"https://api.github.com/users/kripken","html_url":"https://github.com/kripken","followers_url":"https://api.github.com/users/kripken/followers","following_url":"https://api.github.com/users/kripken/following{/other_user}","gists_url":"https://api.github.com/users/kripken/gists{/gist_id}","starred_url":"https://api.github.com/users/kripken/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kripken/subscriptions","organizations_url":"https://api.github.com/users/kripken/orgs","repos_url":"https://api.github.com/users/kripken/repos","events_url":"https://api.github.com/users/kripken/events{/privacy}","received_events_url":"https://api.github.com/users/kripken/received_events","type":"User","site_admin":false},"comments":2,"review_comments":7,"maintainer_can_modify":false,"commits":2,"additions":7,"deletions":2,"changed_files":1}}
{"actor":{"display_login":"kripken"}}