{"action":"created","issue":{"url":"https://api.github.com/repos/atom/electron/issues/3482","labels_url":"https://api.github.com/repos/atom/electron/issues/3482/labels{/name}","comments_url":"https://api.github.com/repos/atom/electron/issues/3482/comments","events_url":"https://api.github.com/repos/atom/electron/issues/3482/events","html_url":"https://github.com/atom/electron/issues/3482","id":117477999,"number":3482,"title":"child_process.execSync causes error: write EBADF","user":{"login":"davej","id":26971,"avatar_url":"https://avatars.githubusercontent.com/u/26971?v=3","gravatar_id":"","url":"https://api.github.com/users/davej","html_url":"https://github.com/davej","followers_url":"https://api.github.com/users/davej/followers","following_url":"https://api.github.com/users/davej/following{/other_user}","gists_url":"https://api.github.com/users/davej/gists{/gist_id}","starred_url":"https://api.github.com/users/davej/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davej/subscriptions","organizations_url":"https://api.github.com/users/davej/orgs","repos_url":"https://api.github.com/users/davej/repos","events_url":"https://api.github.com/users/davej/events{/privacy}","received_events_url":"https://api.github.com/users/davej/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/atom/electron/labels/more-information-needed","name":"more-information-needed","color":"009800"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-11-17T23:47:20Z","updated_at":"2015-11-18T10:46:31Z","closed_at":null,"body":"Seeing this issue in the renderer process (works fine in main process) of 0.34.3 on Yosemite. `child_process.exec` is fine, only `execSync` fails.\r\n\r\nTo recreate in the renderer, just do:\r\n```js\r\nrequire('child_process').execSync('echo $PATH');\r\n```\r\n\r\nThe error backtrace:\r\n```\r\nevents.js:141 Uncaught Error: write EBADF\r\nexports._errnoException @ util.js:837\r\nexports._exceptionWithHostPort @ util.js:860\r\nafterWrite @ net.js:760\r\n```\r\n<img width=\"912\" alt=\"screen shot 2015-11-17 at 22 54 28\" src=\"https://cloud.githubusercontent.com/assets/26971/11227494/31dcee1a-8d7e-11e5-86b1-d7db990bb692.png\">\r\n\r\nPossibly related to: https://github.com/atom/electron/issues/1471"},"comment":{"url":"https://api.github.com/repos/atom/electron/issues/comments/157676390","html_url":"https://github.com/atom/electron/issues/3482#issuecomment-157676390","issue_url":"https://api.github.com/repos/atom/electron/issues/3482","id":157676390,"user":{"login":"zcbenz","id":639601,"avatar_url":"https://avatars.githubusercontent.com/u/639601?v=3","gravatar_id":"","url":"https://api.github.com/users/zcbenz","html_url":"https://github.com/zcbenz","followers_url":"https://api.github.com/users/zcbenz/followers","following_url":"https://api.github.com/users/zcbenz/following{/other_user}","gists_url":"https://api.github.com/users/zcbenz/gists{/gist_id}","starred_url":"https://api.github.com/users/zcbenz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zcbenz/subscriptions","organizations_url":"https://api.github.com/users/zcbenz/orgs","repos_url":"https://api.github.com/users/zcbenz/repos","events_url":"https://api.github.com/users/zcbenz/events{/privacy}","received_events_url":"https://api.github.com/users/zcbenz/received_events","type":"User","site_admin":true},"created_at":"2015-11-18T10:46:31Z","updated_at":"2015-11-18T10:46:31Z","body":"Does the error happen if you call `require('child_process').execSync('echo $PATH', {stdio: 'ignore'});`?"}}