diff options
author | Peter Collingbourne <peter@pcc.me.uk> | 2012-02-20 21:20:45 (GMT) |
---|---|---|
committer | Peter Collingbourne <peter@pcc.me.uk> | 2012-02-21 02:06:51 (GMT) |
commit | 6cf2f5a98608ad1aeeae791fbba6bfacbf135538 (patch) | |
tree | 7ae022034a315242bca9f133d126114e1cde4b7b /src | |
parent | 0eebd5fe1dec021a63110ecab8fa411f9980745f (diff) | |
download | Ninja-6cf2f5a98608ad1aeeae791fbba6bfacbf135538.zip Ninja-6cf2f5a98608ad1aeeae791fbba6bfacbf135538.tar.gz Ninja-6cf2f5a98608ad1aeeae791fbba6bfacbf135538.tar.bz2 |
Do not reload the manifest if a restat cleans it while being rebuilt
Diffstat (limited to 'src')
-rw-r--r-- | src/ninja.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/ninja.cc b/src/ninja.cc index 6cc2276..7f07053 100644 --- a/src/ninja.cc +++ b/src/ninja.cc @@ -150,7 +150,12 @@ bool RebuildManifest(State* state, const BuildConfig& config, if (manifest_builder.AlreadyUpToDate()) return false; // Not an error, but we didn't rebuild. - return manifest_builder.Build(err); + if (!manifest_builder.Build(err)) + return false; + + // The manifest was only rebuilt if it is now dirty (it may have been cleaned + // by a restat). + return node->dirty(); } bool CollectTargetsFromArgs(State* state, int argc, char* argv[], |