Make LDB quit on a ^D from a TTY instead of just ignoring the EOF.
* More consistent with the normal REPL
* The old behaviour would occasionally cause an infinite loop
of printing the LDB prompt, trying to read input, finding that
the tty was closed, printing the prompt again, etc.
fflush(stdout);
line = fgets(buf, sizeof(buf), ldb_in);
if (line == NULL) {
- if (isatty(ldb_in_fd)) {
- putchar('\n');
- continue;
- }
- else {
- fprintf(stderr, "\nEOF on something other than a tty.\n");
- exit(0);
- }
+ exit(1);
}
ptr = line;
if ((token = parse_token(&ptr)) == NULL)
;;; checkins which aren't released. (And occasionally for internal
;;; versions, especially for internal versions off the main CVS
;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
-"0.9.8"
+"0.9.8.1"