Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 557a0c50 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "AAPT2: binary parser should be more lenient with files" into oc-dev

parents f6bc1402 742888f0
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -213,10 +213,10 @@ class OptimizeCommand {

            if (file_ref->file == nullptr) {
              ResourceNameRef name(pkg->name, type->type, entry->name);
              context_->GetDiagnostics()->Error(DiagMessage(file_ref->GetSource())
              context_->GetDiagnostics()->Warn(DiagMessage(file_ref->GetSource())
                                                << "file for resource " << name << " with config '"
                                                << config_value->config << "' not found");
              return false;
              continue;
            }

            const StringPiece entry_name = entry->name;
+1 −2
Original line number Diff line number Diff line
@@ -439,11 +439,10 @@ std::unique_ptr<Item> BinaryResourceParser::ParseValue(const ResourceNameRef& na
    if (file_ref != nullptr) {
      file_ref->file = files_->FindFile(*file_ref->path);
      if (file_ref->file == nullptr) {
        context_->GetDiagnostics()->Error(DiagMessage() << "resource " << name << " for config '"
        context_->GetDiagnostics()->Warn(DiagMessage() << "resource " << name << " for config '"
                                                        << config << "' is a file reference to '"
                                                        << *file_ref->path
                                                        << "' but no such path exists");
        return {};
      }
    }
  }