From 924d56a4d2d8b16530cd378b18cfc5d6e08420ed Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Sat, 13 Aug 2011 21:10:15 -0700 Subject: 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 --- altosui/AltosDebug.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'altosui/AltosDebug.java') 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; } } -- cgit v1.2.3