summaryrefslogtreecommitdiffstats
path: root/fastboot
diff options
context:
space:
mode:
authorScott Anderson <saa@android.com>2012-06-04 20:29:11 -0700
committerScott Anderson <saa@android.com>2012-06-05 11:13:45 -0700
commit866b1bd5051db4f22b634df1f8a06bc1c9aa2e26 (patch)
treea70fdf39a3ae0eb9b832743394f71e4aa6518ae8 /fastboot
parent2ca3e6b35f79136418ebc32fef57580698dbd045 (diff)
downloadsystem_core-866b1bd5051db4f22b634df1f8a06bc1c9aa2e26.zip
system_core-866b1bd5051db4f22b634df1f8a06bc1c9aa2e26.tar.gz
system_core-866b1bd5051db4f22b634df1f8a06bc1c9aa2e26.tar.bz2
fastboot: Make the format of "devices -l" match adb's
Change-Id: Iec7b02fee8298a4437d1827623e9f61688a73f42 Signed-off-by: Scott Anderson <saa@android.com>
Diffstat (limited to 'fastboot')
-rw-r--r--fastboot/fastboot.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/fastboot/fastboot.c b/fastboot/fastboot.c
index f1b675f..6e42436 100644
--- a/fastboot/fastboot.c
+++ b/fastboot/fastboot.c
@@ -181,15 +181,13 @@ int list_devices_callback(usb_ifc_info *info)
if (!serial[0]) {
serial = "????????????";
}
+ // output compatible with "adb devices"
if (!long_listing) {
- // output compatible with "adb devices"
printf("%s\tfastboot\n", serial);
+ } else if (!info->device_path) {
+ printf("%-22s fastboot\n", serial);
} else {
- char* device_path = info->device_path;
- if (!device_path[0]) {
- device_path = "????????????";
- }
- printf("%s\t%s\tfastboot\n", serial, device_path);
+ printf("%-22s fastboot %s\n", serial, info->device_path);
}
}