Merge from vscode a5cf1da01d5db3d2557132be8d30f89c38019f6c (#8525)

* Merge from vscode a5cf1da01d5db3d2557132be8d30f89c38019f6c

* remove files we don't want

* fix hygiene

* update distro

* update distro

* fix hygiene

* fix strict nulls

* distro

* distro

* fix tests

* fix tests

* add another edit

* fix viewlet icon

* fix azure dialog

* fix some padding

* fix more padding issues
This commit is contained in:
Anthony Dresser
2019-12-04 19:28:22 -08:00
committed by GitHub
parent a8818ab0df
commit f5ce7fb2a5
1507 changed files with 42813 additions and 27370 deletions

21
src/bootstrap-fork.js vendored
View File

@@ -20,11 +20,6 @@ if (!!process.send && process.env.PIPE_LOGGING === 'true') {
pipeLoggingToParent();
}
// Disable IO if configured
if (!process.env['VSCODE_ALLOW_IO']) {
disableSTDIO();
}
// Handle Exceptions
if (!process.env['VSCODE_HANDLES_UNCAUGHT_ERRORS']) {
handleExceptions();
@@ -141,20 +136,6 @@ function pipeLoggingToParent() {
console.error = function () { safeSend({ type: '__$console', severity: 'error', arguments: safeToArray(arguments) }); };
}
function disableSTDIO() {
// const stdout, stderr and stdin be no-op streams. This prevents an issue where we would get an EBADF
// error when we are inside a forked process and this process tries to access those channels.
const stream = require('stream');
const writable = new stream.Writable({
write: function () { /* No OP */ }
});
process['__defineGetter__']('stdout', function () { return writable; });
process['__defineGetter__']('stderr', function () { return writable; });
process['__defineGetter__']('stdin', function () { return writable; });
}
function handleExceptions() {
// Handle uncaught exceptions
@@ -198,4 +179,4 @@ function configureCrashReporter() {
}
}
//#endregion
//#endregion