summaryrefslogtreecommitdiffstats
path: root/src/usb-device.c
diff options
context:
space:
mode:
authorPali Rohár <pali.rohar@gmail.com>2012-11-20 21:52:03 +0100
committerPali Rohár <pali.rohar@gmail.com>2012-11-20 21:52:03 +0100
commit067c84ea2ca76dd67a5eda057147967d2ac6e2ef (patch)
tree6668c4cecbbd108f7de20ef92c4e1ad95563f9fa /src/usb-device.c
parent29c2b606702f18ef4a5b50a13cd517b4adf8b373 (diff)
download0xFFFF-067c84ea2ca76dd67a5eda057147967d2ac6e2ef.tar.bz2
usb-device: Fix usb_switch_to_cold
Diffstat (limited to 'src/usb-device.c')
-rw-r--r--src/usb-device.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/usb-device.c b/src/usb-device.c
index 33009be..e2290b6 100644
--- a/src/usb-device.c
+++ b/src/usb-device.c
@@ -307,7 +307,9 @@ void usb_switch_to_nolo(struct usb_device_info * dev) {
void usb_switch_to_cold(struct usb_device_info * dev) {
printf("\nSwitching to Cold Flash mode...\n");
- printf_and_wait("Unplug USB cable, turn device off, press ENTER and plug USB cable again");
+
+ if ( dev->flash_device->protocol != FLASH_COLD )
+ printf_and_wait("Unplug USB cable, turn device off, press ENTER and plug USB cable again");
}