{"action":"created","comment":{"url":"https://api.github.com/repos/symfony/symfony/pulls/comments/77804688","id":77804688,"diff_hunk":"@@ -554,8 +554,7 @@ public function dumpFile($filename, $content)\n             throw new IOException(sprintf('Failed to write file \"%s\".', $filename), 0, null, $filename);\n         }\n \n-        // Ignore for filesystems that do not support umask\n-        @chmod($tmpFile, 0666);\n+        @chmod($tmpFile, 0666 & ~umask());","path":"src/Symfony/Component/Filesystem/Filesystem.php","position":6,"original_position":6,"commit_id":"8c7202c68c591696fc023482b34fe6efddfe0eb1","original_commit_id":"8c7202c68c591696fc023482b34fe6efddfe0eb1","user":{"login":"hboomsma","id":1465009,"avatar_url":"https://avatars.githubusercontent.com/u/1465009?v=3","gravatar_id":"","url":"https://api.github.com/users/hboomsma","html_url":"https://github.com/hboomsma","followers_url":"https://api.github.com/users/hboomsma/followers","following_url":"https://api.github.com/users/hboomsma/following{/other_user}","gists_url":"https://api.github.com/users/hboomsma/gists{/gist_id}","starred_url":"https://api.github.com/users/hboomsma/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hboomsma/subscriptions","organizations_url":"https://api.github.com/users/hboomsma/orgs","repos_url":"https://api.github.com/users/hboomsma/repos","events_url":"https://api.github.com/users/hboomsma/events{/privacy}","received_events_url":"https://api.github.com/users/hboomsma/received_events","type":"User","site_admin":false},"body":"Can you also adjust the test case to test this behavior? (be aware of windows not having umask)","created_at":"2016-09-07T11:32:53Z","updated_at":"2016-09-07T11:32:53Z","html_url":"https://github.com/symfony/symfony/pull/19872#discussion_r77804688","pull_request_url":"https://api.github.com/repos/symfony/symfony/pulls/19872","_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony/pulls/comments/77804688"},"html":{"href":"https://github.com/symfony/symfony/pull/19872#discussion_r77804688"},"pull_request":{"href":"https://api.github.com/repos/symfony/symfony/pulls/19872"}}},"pull_request":{"url":"https://api.github.com/repos/symfony/symfony/pulls/19872","id":84126249,"html_url":"https://github.com/symfony/symfony/pull/19872","diff_url":"https://github.com/symfony/symfony/pull/19872.diff","patch_url":"https://github.com/symfony/symfony/pull/19872.patch","issue_url":"https://api.github.com/repos/symfony/symfony/issues/19872","number":19872,"state":"open","locked":false,"title":"Consider the umask setting when dumping a file","user":{"login":"leofeyer","id":1192057,"avatar_url":"https://avatars.githubusercontent.com/u/1192057?v=3","gravatar_id":"","url":"https://api.github.com/users/leofeyer","html_url":"https://github.com/leofeyer","followers_url":"https://api.github.com/users/leofeyer/followers","following_url":"https://api.github.com/users/leofeyer/following{/other_user}","gists_url":"https://api.github.com/users/leofeyer/gists{/gist_id}","starred_url":"https://api.github.com/users/leofeyer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leofeyer/subscriptions","organizations_url":"https://api.github.com/users/leofeyer/orgs","repos_url":"https://api.github.com/users/leofeyer/repos","events_url":"https://api.github.com/users/leofeyer/events{/privacy}","received_events_url":"https://api.github.com/users/leofeyer/received_events","type":"User","site_admin":false},"body":"| Q             | A\r\n| ------------- | ---\r\n| Branch?       | 3.1\r\n| Bug fix?      | yes\r\n| New feature?  | no\r\n| BC breaks?    | no\r\n| Deprecations? | no\r\n| Tests pass?   | yes\r\n| Fixed tickets | #14246 , #17063\r\n| License       | MIT\r\n| Doc PR        | -\r\n\r\n`Filesystem::dumpFile()` does not consider the umask setting and thus creates files with write permissions for everyone (`0666`). Other `chmod()` calls in Symfony do consider the umask setting (see e.g. [here](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpFoundation/File/File.php#L101) or [here](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpFoundation/File/UploadedFile.php#L230)), therefore I have adjusted the `dumpFile()` method accordingly.\r\n","created_at":"2016-09-06T13:52:58Z","updated_at":"2016-09-07T11:32:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f3f00c927d165c2868851d12af901250e4838084","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/symfony/symfony/pulls/19872/commits","review_comments_url":"https://api.github.com/repos/symfony/symfony/pulls/19872/comments","review_comment_url":"https://api.github.com/repos/symfony/symfony/pulls/comments{/number}","comments_url":"https://api.github.com/repos/symfony/symfony/issues/19872/comments","statuses_url":"https://api.github.com/repos/symfony/symfony/statuses/8c7202c68c591696fc023482b34fe6efddfe0eb1","head":{"label":"leofeyer:hotfix/dump-file-chmod","ref":"hotfix/dump-file-chmod","sha":"8c7202c68c591696fc023482b34fe6efddfe0eb1","user":{"login":"leofeyer","id":1192057,"avatar_url":"https://avatars.githubusercontent.com/u/1192057?v=3","gravatar_id":"","url":"https://api.github.com/users/leofeyer","html_url":"https://github.com/leofeyer","followers_url":"https://api.github.com/users/leofeyer/followers","following_url":"https://api.github.com/users/leofeyer/following{/other_user}","gists_url":"https://api.github.com/users/leofeyer/gists{/gist_id}","starred_url":"https://api.github.com/users/leofeyer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leofeyer/subscriptions","organizations_url":"https://api.github.com/users/leofeyer/orgs","repos_url":"https://api.github.com/users/leofeyer/repos","events_url":"https://api.github.com/users/leofeyer/events{/privacy}","received_events_url":"https://api.github.com/users/leofeyer/received_events","type":"User","site_admin":false},"repo":{"id":64766179,"name":"symfony","full_name":"leofeyer/symfony","owner":{"login":"leofeyer","id":1192057,"avatar_url":"https://avatars.githubusercontent.com/u/1192057?v=3","gravatar_id":"","url":"https://api.github.com/users/leofeyer","html_url":"https://github.com/leofeyer","followers_url":"https://api.github.com/users/leofeyer/followers","following_url":"https://api.github.com/users/leofeyer/following{/other_user}","gists_url":"https://api.github.com/users/leofeyer/gists{/gist_id}","starred_url":"https://api.github.com/users/leofeyer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leofeyer/subscriptions","organizations_url":"https://api.github.com/users/leofeyer/orgs","repos_url":"https://api.github.com/users/leofeyer/repos","events_url":"https://api.github.com/users/leofeyer/events{/privacy}","received_events_url":"https://api.github.com/users/leofeyer/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/leofeyer/symfony","description":"The Symfony PHP framework","fork":true,"url":"https://api.github.com/repos/leofeyer/symfony","forks_url":"https://api.github.com/repos/leofeyer/symfony/forks","keys_url":"https://api.github.com/repos/leofeyer/symfony/keys{/key_id}","collaborators_url":"https://api.github.com/repos/leofeyer/symfony/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/leofeyer/symfony/teams","hooks_url":"https://api.github.com/repos/leofeyer/symfony/hooks","issue_events_url":"https://api.github.com/repos/leofeyer/symfony/issues/events{/number}","events_url":"https://api.github.com/repos/leofeyer/symfony/events","assignees_url":"https://api.github.com/repos/leofeyer/symfony/assignees{/user}","branches_url":"https://api.github.com/repos/leofeyer/symfony/branches{/branch}","tags_url":"https://api.github.com/repos/leofeyer/symfony/tags","blobs_url":"https://api.github.com/repos/leofeyer/symfony/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/leofeyer/symfony/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/leofeyer/symfony/git/refs{/sha}","trees_url":"https://api.github.com/repos/leofeyer/symfony/git/trees{/sha}","statuses_url":"https://api.github.com/repos/leofeyer/symfony/statuses/{sha}","languages_url":"https://api.github.com/repos/leofeyer/symfony/languages","stargazers_url":"https://api.github.com/repos/leofeyer/symfony/stargazers","contributors_url":"https://api.github.com/repos/leofeyer/symfony/contributors","subscribers_url":"https://api.github.com/repos/leofeyer/symfony/subscribers","subscription_url":"https://api.github.com/repos/leofeyer/symfony/subscription","commits_url":"https://api.github.com/repos/leofeyer/symfony/commits{/sha}","git_commits_url":"https://api.github.com/repos/leofeyer/symfony/git/commits{/sha}","comments_url":"https://api.github.com/repos/leofeyer/symfony/comments{/number}","issue_comment_url":"https://api.github.com/repos/leofeyer/symfony/issues/comments{/number}","contents_url":"https://api.github.com/repos/leofeyer/symfony/contents/{+path}","compare_url":"https://api.github.com/repos/leofeyer/symfony/compare/{base}...{head}","merges_url":"https://api.github.com/repos/leofeyer/symfony/merges","archive_url":"https://api.github.com/repos/leofeyer/symfony/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/leofeyer/symfony/downloads","issues_url":"https://api.github.com/repos/leofeyer/symfony/issues{/number}","pulls_url":"https://api.github.com/repos/leofeyer/symfony/pulls{/number}","milestones_url":"https://api.github.com/repos/leofeyer/symfony/milestones{/number}","notifications_url":"https://api.github.com/repos/leofeyer/symfony/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/leofeyer/symfony/labels{/name}","releases_url":"https://api.github.com/repos/leofeyer/symfony/releases{/id}","deployments_url":"https://api.github.com/repos/leofeyer/symfony/deployments","created_at":"2016-08-02T14:56:43Z","updated_at":"2016-08-02T14:57:01Z","pushed_at":"2016-09-06T13:48:39Z","git_url":"git://github.com/leofeyer/symfony.git","ssh_url":"git@github.com:leofeyer/symfony.git","clone_url":"https://github.com/leofeyer/symfony.git","svn_url":"https://github.com/leofeyer/symfony","homepage":"symfony.com","size":69497,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_downloads":false,"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":"symfony:3.1","ref":"3.1","sha":"c5aa4f0a7e3e2ca13d5a21daeb2ba6f734dc8320","user":{"login":"symfony","id":143937,"avatar_url":"https://avatars.githubusercontent.com/u/143937?v=3","gravatar_id":"","url":"https://api.github.com/users/symfony","html_url":"https://github.com/symfony","followers_url":"https://api.github.com/users/symfony/followers","following_url":"https://api.github.com/users/symfony/following{/other_user}","gists_url":"https://api.github.com/users/symfony/gists{/gist_id}","starred_url":"https://api.github.com/users/symfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/symfony/subscriptions","organizations_url":"https://api.github.com/users/symfony/orgs","repos_url":"https://api.github.com/users/symfony/repos","events_url":"https://api.github.com/users/symfony/events{/privacy}","received_events_url":"https://api.github.com/users/symfony/received_events","type":"Organization","site_admin":false},"repo":{"id":458058,"name":"symfony","full_name":"symfony/symfony","owner":{"login":"symfony","id":143937,"avatar_url":"https://avatars.githubusercontent.com/u/143937?v=3","gravatar_id":"","url":"https://api.github.com/users/symfony","html_url":"https://github.com/symfony","followers_url":"https://api.github.com/users/symfony/followers","following_url":"https://api.github.com/users/symfony/following{/other_user}","gists_url":"https://api.github.com/users/symfony/gists{/gist_id}","starred_url":"https://api.github.com/users/symfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/symfony/subscriptions","organizations_url":"https://api.github.com/users/symfony/orgs","repos_url":"https://api.github.com/users/symfony/repos","events_url":"https://api.github.com/users/symfony/events{/privacy}","received_events_url":"https://api.github.com/users/symfony/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/symfony/symfony","description":"The Symfony PHP framework","fork":false,"url":"https://api.github.com/repos/symfony/symfony","forks_url":"https://api.github.com/repos/symfony/symfony/forks","keys_url":"https://api.github.com/repos/symfony/symfony/keys{/key_id}","collaborators_url":"https://api.github.com/repos/symfony/symfony/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/symfony/symfony/teams","hooks_url":"https://api.github.com/repos/symfony/symfony/hooks","issue_events_url":"https://api.github.com/repos/symfony/symfony/issues/events{/number}","events_url":"https://api.github.com/repos/symfony/symfony/events","assignees_url":"https://api.github.com/repos/symfony/symfony/assignees{/user}","branches_url":"https://api.github.com/repos/symfony/symfony/branches{/branch}","tags_url":"https://api.github.com/repos/symfony/symfony/tags","blobs_url":"https://api.github.com/repos/symfony/symfony/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/symfony/symfony/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/symfony/symfony/git/refs{/sha}","trees_url":"https://api.github.com/repos/symfony/symfony/git/trees{/sha}","statuses_url":"https://api.github.com/repos/symfony/symfony/statuses/{sha}","languages_url":"https://api.github.com/repos/symfony/symfony/languages","stargazers_url":"https://api.github.com/repos/symfony/symfony/stargazers","contributors_url":"https://api.github.com/repos/symfony/symfony/contributors","subscribers_url":"https://api.github.com/repos/symfony/symfony/subscribers","subscription_url":"https://api.github.com/repos/symfony/symfony/subscription","commits_url":"https://api.github.com/repos/symfony/symfony/commits{/sha}","git_commits_url":"https://api.github.com/repos/symfony/symfony/git/commits{/sha}","comments_url":"https://api.github.com/repos/symfony/symfony/comments{/number}","issue_comment_url":"https://api.github.com/repos/symfony/symfony/issues/comments{/number}","contents_url":"https://api.github.com/repos/symfony/symfony/contents/{+path}","compare_url":"https://api.github.com/repos/symfony/symfony/compare/{base}...{head}","merges_url":"https://api.github.com/repos/symfony/symfony/merges","archive_url":"https://api.github.com/repos/symfony/symfony/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/symfony/symfony/downloads","issues_url":"https://api.github.com/repos/symfony/symfony/issues{/number}","pulls_url":"https://api.github.com/repos/symfony/symfony/pulls{/number}","milestones_url":"https://api.github.com/repos/symfony/symfony/milestones{/number}","notifications_url":"https://api.github.com/repos/symfony/symfony/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/symfony/symfony/labels{/name}","releases_url":"https://api.github.com/repos/symfony/symfony/releases{/id}","deployments_url":"https://api.github.com/repos/symfony/symfony/deployments","created_at":"2010-01-04T14:21:21Z","updated_at":"2016-09-07T10:16:19Z","pushed_at":"2016-09-07T11:06:46Z","git_url":"git://github.com/symfony/symfony.git","ssh_url":"git@github.com:symfony/symfony.git","clone_url":"https://github.com/symfony/symfony.git","svn_url":"https://github.com/symfony/symfony","homepage":"symfony.com","size":135492,"stargazers_count":12920,"watchers_count":12920,"language":"PHP","has_issues":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":5023,"mirror_url":null,"open_issues_count":767,"forks":5023,"open_issues":767,"watchers":12920,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony/pulls/19872"},"html":{"href":"https://github.com/symfony/symfony/pull/19872"},"issue":{"href":"https://api.github.com/repos/symfony/symfony/issues/19872"},"comments":{"href":"https://api.github.com/repos/symfony/symfony/issues/19872/comments"},"review_comments":{"href":"https://api.github.com/repos/symfony/symfony/pulls/19872/comments"},"review_comment":{"href":"https://api.github.com/repos/symfony/symfony/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/symfony/symfony/pulls/19872/commits"},"statuses":{"href":"https://api.github.com/repos/symfony/symfony/statuses/8c7202c68c591696fc023482b34fe6efddfe0eb1"}}}}
{"actor":{"display_login":"hboomsma"}}