Merge "Fix segmentation fault in aapt2"

This commit is contained in:
TreeHugger Robot
2021-05-10 21:14:20 +00:00
committed by Android (Google) Code Review

View File

@@ -135,7 +135,8 @@ class ManifestExtractor {
template <typename Predicate>
void Filter(Predicate&& func) {
children_.erase(std::remove_if(children_.begin(), children_.end(),
[&](const auto& e) { return func(e.get()); }));
[&](const auto& e) { return func(e.get()); }),
children_.end());
}
/** Retrieves the list of children of the element. */