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

Commit fe7f2feb authored by Ryan Mitchell's avatar Ryan Mitchell Committed by android-build-merger
Browse files

Merge "Fix memory leak in aapt2" am: 5491eb92

am: f26f7a20

Change-Id: I658bb39d0252e503677ffbb0db3d298716f33a64
parents 48547ce1 f26f7a20
Loading
Loading
Loading
Loading
+3 −8
Original line number Diff line number Diff line
@@ -169,17 +169,12 @@ int MainImpl(int argc, char** argv) {
  aapt::text::Printer printer(&fout);

  aapt::StdErrDiagnostics diagnostics;
  auto main_command = new aapt::MainCommand(&printer, &diagnostics);
  aapt::MainCommand main_command(&printer, &diagnostics);

  // Add the daemon subcommand here so it cannot be called while executing the daemon
  main_command->AddOptionalSubcommand(
  main_command.AddOptionalSubcommand(
      aapt::util::make_unique<aapt::DaemonCommand>(&fout, &diagnostics));
  return main_command->Execute(args, &std::cerr);
}

// TODO(b/141312058) stop leaks
extern "C" const char *__asan_default_options() {
    return "detect_leaks=0";
  return main_command.Execute(args, &std::cerr);
}

int main(int argc, char** argv) {