diff options
author | Christopher Faylor <me@cgf.cx> | 2002-12-20 01:38:55 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2002-12-20 01:38:55 +0000 |
commit | 388aa9941b2432a02513283858cac6c74bb25a0d (patch) | |
tree | 7f10f872a8b5500b5dd8750c31acbb24b24106c2 /winsup/cygwin/fhandler_termios.cc | |
parent | e9f731caf79a961f6c4fc56e30cfda65343786a4 (diff) | |
download | cygnal-388aa9941b2432a02513283858cac6c74bb25a0d.tar.gz cygnal-388aa9941b2432a02513283858cac6c74bb25a0d.tar.bz2 cygnal-388aa9941b2432a02513283858cac6c74bb25a0d.zip |
* fhandler.h (line_edit_status): Add a new element.
* fhandler_termios.cc (fhandler_termios::line_edit): After accept_input, handle
both potential error condition and pipe full conditions.
* fhandler_tty.cc (fhandler_pty_master::accept_input): Return -1 on error.
(fhandler_pty_master::write): Handle pipe full condition.
Diffstat (limited to 'winsup/cygwin/fhandler_termios.cc')
-rw-r--r-- | winsup/cygwin/fhandler_termios.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/winsup/cygwin/fhandler_termios.cc b/winsup/cygwin/fhandler_termios.cc index e6a113241..9cd2561fa 100644 --- a/winsup/cygwin/fhandler_termios.cc +++ b/winsup/cygwin/fhandler_termios.cc @@ -326,9 +326,10 @@ fhandler_termios::line_edit (const char *rptr, int nread, int always_accept) put_readahead (c); if (!iscanon || always_accept || input_done) { - if (!accept_input ()) + int status = accept_input (); + if (status != 1) { - ret = line_edit_error; + ret = status ? line_edit_error : line_edit_pipe_full; eat_readahead (1); break; } |