summaryrefslogtreecommitdiff
path: root/src/mongo/shell/servers.js
diff options
context:
space:
mode:
authorAli Mir <ali.mir@mongodb.com>2020-09-11 14:07:06 -0400
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-09-21 14:16:33 +0000
commit8797f3b34d6602db8b44f93e345cec38058508e5 (patch)
tree78df429362e9f136815f922b42f68e16b759fc49 /src/mongo/shell/servers.js
parent1f18dc5ce618f61e54d2ac203cbf16b8d388c862 (diff)
downloadmongo-8797f3b34d6602db8b44f93e345cec38058508e5.tar.gz
SERVER-50072 Check _isWindows() when initializing MongoRunner.EXIT_ABORT
Diffstat (limited to 'src/mongo/shell/servers.js')
-rw-r--r--src/mongo/shell/servers.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mongo/shell/servers.js b/src/mongo/shell/servers.js
index 4d7a045db5d..2dcff0c0869 100644
--- a/src/mongo/shell/servers.js
+++ b/src/mongo/shell/servers.js
@@ -959,7 +959,8 @@ MongoRunner.StopError.prototype = Object.create(Error.prototype);
MongoRunner.StopError.prototype.constructor = MongoRunner.StopError;
// Constants for exit codes of MongoDB processes
-MongoRunner.EXIT_ABORT = -6;
+// On Windows, std::abort causes the process to exit with return code 14.
+MongoRunner.EXIT_ABORT = _isWindows() ? 14 : -6;
MongoRunner.EXIT_CLEAN = 0;
MongoRunner.EXIT_BADOPTIONS = 2;
MongoRunner.EXIT_REPLICATION_ERROR = 3;