From d06e3c12ffef42ad845dbd2883e7921a5f89f64d Mon Sep 17 00:00:00 2001 From: Richard Geary Date: Wed, 26 Sep 2012 04:40:33 -0400 Subject: Exit status = 2 if user presses ctrl-c Change-Id: I7be958e18eb2e434e78afb6e03b332281a651957 --- src/ninja.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/ninja.cc b/src/ninja.cc index ad56f1c..a5e8d81 100644 --- a/src/ninja.cc +++ b/src/ninja.cc @@ -682,6 +682,9 @@ int RunBuild(Builder* builder, int argc, char** argv) { if (!builder->Build(&err)) { printf("ninja: build stopped: %s.\n", err.c_str()); + if (err.find("interrupted by user") != string::npos) { + return 2; + } return 1; } -- cgit v0.12