summaryrefslogtreecommitdiff
path: root/altosui/AltosDebug.java
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2011-08-13 21:10:15 -0700
committerKeith Packard <keithp@keithp.com>2011-08-13 21:10:15 -0700
commit924d56a4d2d8b16530cd378b18cfc5d6e08420ed (patch)
tree5ef26000b726f86d861c9838f706382df72d2a36 /altosui/AltosDebug.java
parentdcd15032eec45f3fdd003050710ebd5b85052662 (diff)
altos: AltosSerial.flush_input shouldn't discard Interrupted exceptions
The eeprom download code wants to interrupt serial communication so that it can stop downloading stuff in the middle of a run. Make flush_input pass the exception along instead of discarding it. Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'altosui/AltosDebug.java')
-rw-r--r--altosui/AltosDebug.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/altosui/AltosDebug.java b/altosui/AltosDebug.java
index 8d435b66..d18de80d 100644
--- a/altosui/AltosDebug.java
+++ b/altosui/AltosDebug.java
@@ -62,7 +62,10 @@ public class AltosDebug extends AltosSerial {
void ensure_debug_mode() {
if (!debug_mode) {
printf("D\n");
- flush_input();
+ try {
+ flush_input();
+ } catch (InterruptedException ie) {
+ }
debug_mode = true;
}
}