Recovery of release 990110 after disk crash.
See Changelog for changes between 990103 and 990110.
diff --git a/debugger/editline.c b/debugger/editline.c
index 51e7046..68645fc 100644
--- a/debugger/editline.c
+++ b/debugger/editline.c
@@ -28,6 +28,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <errno.h>
#include <sys/ioctl.h>
#include <sys/types.h>
#include <sys/stat.h>
@@ -279,6 +280,7 @@
TTYget()
{
CHAR c;
+ int retv;
TTYflush();
if (Pushed) {
@@ -287,7 +289,14 @@
}
if (*Input)
return *Input++;
- return read(0, &c, (size_t)1) == 1 ? c : EOF;
+
+ while ( ( retv = read( 0, &c, (size_t)1 ) ) == -1 )
+ {
+ if ( errno != EINTR )
+ perror( "read" );
+ }
+
+ return retv == 1 ? c : EOF;
}
#define TTYback() (backspace ? TTYputs((CHAR *)backspace) : TTYput('\b'))