Changeset 16002
- Timestamp:
- Jan 4, 2008, 11:24:10 AM (18 years ago)
- File:
-
- 1 edited
-
trunk/Ohana/src/opihi/lib.shell/multicommand.c (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/opihi/lib.shell/multicommand.c
r12404 r16002 2 2 3 3 static int server = 0; 4 static int bufferPending = FALSE; 4 5 5 6 // XXX this is rather pantasks-specific... … … 55 56 if (*tmpline) { 56 57 58 if (bufferPending) { 59 // flush old messages 60 while (ExpectMessage (server, 0.2, &message)); 61 bufferPending = FALSE; 62 } 63 57 64 status = command (tmpline, &outline, verbose); 58 65 … … 66 73 exit (1); 67 74 default: 68 gprint (GP_ERR, "I/O error sending server message\n"); 69 exit (2); 75 gprint (GP_ERR, "server is busy...\n"); 76 bufferPending = TRUE; 77 goto escape; 70 78 } 71 79 } … … 78 86 exit (1); 79 87 default: 80 gprint (GP_ERR, "I/O error sending server message\n"); 81 exit (2); 88 gprint (GP_ERR, "server is busy...\n"); 89 bufferPending = TRUE; 90 goto escape; 82 91 } 83 92 } else { … … 92 101 exit (1); 93 102 default: 94 gprint (GP_ERR, "I/O error sending server message\n"); 95 exit (2); 103 gprint (GP_ERR, "server is busy...\n"); 104 bufferPending = TRUE; 105 goto escape; 96 106 } 97 107 } else { … … 106 116 exit (1); 107 117 default: 108 gprint (GP_ERR, "I/O error sending server message\n"); 109 exit (2); 118 gprint (GP_ERR, "server is busy...\n"); 119 bufferPending = TRUE; 120 goto escape; 110 121 } 111 122 } else { … … 117 128 } 118 129 } 119 130 escape: 120 131 if (outline != NULL) free (outline); 121 132 if (!status && auto_break) done = TRUE;
Note:
See TracChangeset
for help on using the changeset viewer.
