diff packages/redboot/current/src/io.c @ 126:518f42066aba ecos-sw-2000-09-19

Merge from eCos master repository on 2000-09-19-06:25:26-BST
author jlarmour
date Tue, 19 Sep 2000 05:53:51 +0000
parents 6ed91473a1cd
children 0c2b7be0d798
line wrap: on
line diff
--- a/packages/redboot/current/src/io.c
+++ b/packages/redboot/current/src/io.c
@@ -107,9 +107,12 @@ mon_read_char_with_timeout(char *c)
             res = CYGACC_COMM_IF_GETC_TIMEOUT(*__chan, c);
             if (res) {
                 // Input available on this channel, make it be the console
-                console_selected = true;
-                CYGACC_CALL_IF_SET_DEBUG_COMM(i);
-                return res;
+                if (*c != '\0') {
+                    // Don't chose this unless real data have arrived
+                    console_selected = true;
+                    CYGACC_CALL_IF_SET_DEBUG_COMM(i);
+                    return res;
+                }
             }
         }
         CYGACC_CALL_IF_SET_CONSOLE_COMM(cur);