summaryrefslogtreecommitdiffstats
path: root/src/missing_deps.cc
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2021-06-03 21:19:05 (GMT)
committerBrad King <brad.king@kitware.com>2021-06-04 15:17:52 (GMT)
commit91706b323fcb2da9a87656d00ebbaf939ed8dad7 (patch)
treedfea64debf9d986d2f1ec14d525809b03e92c535 /src/missing_deps.cc
parentf2f62e295ad1254b7e3cdd5d78fa8afb0e86f1ce (diff)
downloadNinja-91706b323fcb2da9a87656d00ebbaf939ed8dad7.zip
Ninja-91706b323fcb2da9a87656d00ebbaf939ed8dad7.tar.gz
Ninja-91706b323fcb2da9a87656d00ebbaf939ed8dad7.tar.bz2
util: Remove unnecessary CanonicalizePath error handling
Since commit 86f606fe (Remove path component limit from input of CanonicalizePath in windows, 2017-08-30, v1.8.0^2~2^2), the only failure case in the `CanonicalizePath` implementation is the "empty path" error. All call sites have been updated to ensure `CanonicalizePath` is never called with an empty path. Remove error handling from the signature to simplify call sites.
Diffstat (limited to 'src/missing_deps.cc')
-rw-r--r--src/missing_deps.cc4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/missing_deps.cc b/src/missing_deps.cc
index eaa3f73..78feb49 100644
--- a/src/missing_deps.cc
+++ b/src/missing_deps.cc
@@ -52,9 +52,7 @@ bool NodeStoringImplicitDepLoader::ProcessDepfileDeps(
for (std::vector<StringPiece>::iterator i = depfile_ins->begin();
i != depfile_ins->end(); ++i) {
uint64_t slash_bits;
- if (!CanonicalizePath(const_cast<char*>(i->str_), &i->len_, &slash_bits,
- err))
- return false;
+ CanonicalizePath(const_cast<char*>(i->str_), &i->len_, &slash_bits);
Node* node = state_->GetNode(*i, slash_bits);
dep_nodes_output_->push_back(node);
}