diff options
Diffstat (limited to 'tools/aapt2/cmd/Diff.cpp')
-rw-r--r-- | tools/aapt2/cmd/Diff.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/tools/aapt2/cmd/Diff.cpp b/tools/aapt2/cmd/Diff.cpp index 1a6f348a3edc..fc1f1d6342ae 100644 --- a/tools/aapt2/cmd/Diff.cpp +++ b/tools/aapt2/cmd/Diff.cpp @@ -22,7 +22,7 @@ #include "process/IResourceTableConsumer.h" #include "process/SymbolTable.h" -using android::StringPiece; +using ::android::StringPiece; namespace aapt { @@ -325,9 +325,9 @@ static bool EmitResourceTableDiff(IAaptContext* context, LoadedApk* apk_a, Loade return diff; } -class ZeroingReferenceVisitor : public ValueVisitor { +class ZeroingReferenceVisitor : public DescendingValueVisitor { public: - using ValueVisitor::Visit; + using DescendingValueVisitor::Visit; void Visit(Reference* ref) override { if (ref->name && ref->id) { @@ -357,8 +357,9 @@ int Diff(const std::vector<StringPiece>& args) { return 1; } - std::unique_ptr<LoadedApk> apk_a = LoadedApk::LoadApkFromPath(&context, flags.GetArgs()[0]); - std::unique_ptr<LoadedApk> apk_b = LoadedApk::LoadApkFromPath(&context, flags.GetArgs()[1]); + IDiagnostics* diag = context.GetDiagnostics(); + std::unique_ptr<LoadedApk> apk_a = LoadedApk::LoadApkFromPath(flags.GetArgs()[0], diag); + std::unique_ptr<LoadedApk> apk_b = LoadedApk::LoadApkFromPath(flags.GetArgs()[1], diag); if (!apk_a || !apk_b) { return 1; } |