From f118cd95f1c0b77e5d260fae9479da5e9654f498 Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Tue, 6 Oct 2020 13:44:12 -0700 Subject: [PATCH] Clarify `adb bugreport` failures on pre-N devices. The error was meant to imply "without the filename" but (a) that wasn't spelled out and (b) anyone who did just try the command would probably be unpleasantly surprised by the massive amount of spam on their terminal. So give them copy & paste instead. (I did consider using their supplied filename, but since that's almost certainly blah.zip, it seemed uncool to silently create a large text file called "something.zip"!) Bug: http://b/170225883 Test: untested for lack of a working pre-N device right now Change-Id: I834939c963ca09927ccd4dc5ed8e88c65455838e --- adb/client/bugreport.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/adb/client/bugreport.cpp b/adb/client/bugreport.cpp index f2e722ab8..b765a302b 100644 --- a/adb/client/bugreport.cpp +++ b/adb/client/bugreport.cpp @@ -224,7 +224,8 @@ int Bugreport::DoIt(int argc, const char** argv) { // 'bugreport' would generate a lot of output the user might not be prepared to handle). fprintf(stderr, "Failed to get bugreportz version: 'bugreportz -v' returned '%s' (code %d).\n" - "If the device does not run Android 7.0 or above, try 'adb bugreport' instead.\n", + "If the device does not run Android 7.0 or above, try this instead:\n" + "\tadb bugreport > bugreport.txt\n", bugz_output.c_str(), status); return status != 0 ? status : -1; }