From 1a9da399cb082c0b6bb27d641b783980947c9433 Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Tue, 30 Jul 2019 12:26:31 -0700 Subject: [PATCH] Allow overriding the log path. Bug: https://issuetracker.google.com/112588493 Test: manual Change-Id: Ic273d46544479332b8e031f30feadd1840f2d653 --- adb/adb_utils.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/adb/adb_utils.cpp b/adb/adb_utils.cpp index cf5fbc88d..d1910f1c3 100644 --- a/adb/adb_utils.cpp +++ b/adb/adb_utils.cpp @@ -320,6 +320,10 @@ std::string adb_get_android_dir_path() { } std::string GetLogFilePath() { + // https://issuetracker.google.com/112588493 + const char* path = getenv("ANDROID_ADB_LOG_PATH"); + if (path) return path; + #if defined(_WIN32) const char log_name[] = "adb.log"; WCHAR temp_path[MAX_PATH];