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

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

Merge "Check value in dump before printing" into qt-dev

parents cb86e128 0c0cedff
Loading
Loading
Loading
Loading
+12 −4
Original line number Diff line number Diff line
@@ -129,12 +129,20 @@ class ValueBodyPrinter : public ConstValueVisitor {
    constexpr uint32_t kMask = android::ResTable_map::TYPE_ENUM | android::ResTable_map::TYPE_FLAGS;
    if (attr->type_mask & kMask) {
      for (const auto& symbol : attr->symbols) {
        if (symbol.symbol.name) {
          printer_->Print(symbol.symbol.name.value().entry);

          if (symbol.symbol.id) {
            printer_->Print("(");
            printer_->Print(symbol.symbol.id.value().to_string());
            printer_->Print(")");
          }
        } else if (symbol.symbol.id) {
          printer_->Print(symbol.symbol.id.value().to_string());
        } else {
          printer_->Print("???");
        }

        printer_->Println(StringPrintf("=0x%08x", symbol.value));
      }
    }