aboutsummaryrefslogtreecommitdiffhomepage
path: root/reader.c
diff options
context:
space:
mode:
authorGravatar axel <axel@liljencrantz.se>2009-02-23 06:28:52 +1000
committerGravatar axel <axel@liljencrantz.se>2009-02-23 06:28:52 +1000
commit14c84ffbcbbe0368e61b7bc59d44a1d7bc906d33 (patch)
treea0fbafe2d63e86d5adcd615a7bc70fade00f0803 /reader.c
parentf71c6f3f0e34c034c3dec54289527a68a136749f (diff)
Check return value of a few write calls and retry on EINTR, and fix a few other warnings, mostly by printing error messages before giving up.
darcs-hash:20090222202852-ac50b-b0e79142af5b7a99e55271d4001fa252d9684a1d.gz
Diffstat (limited to 'reader.c')
-rw-r--r--reader.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/reader.c b/reader.c
index 257fe066..f47a417a 100644
--- a/reader.c
+++ b/reader.c
@@ -1577,9 +1577,9 @@ static int handle_completions( array_list_t *comp )
wchar_t quote;
get_param( data->buff, data->buff_pos, &quote, 0, 0, 0 );
is_quoted = (quote != L'\0');
-
- write(1, "\n", 1 );
-
+
+ write_loop(1, "\n", 1 );
+
run_pager( prefix, is_quoted, comp );
}
@@ -2650,7 +2650,7 @@ wchar_t *reader_readline()
case R_REPAINT:
{
exec_prompt();
- write( 1, "\r", 1 );
+ write_loop( 1, "\r", 1 );
s_reset( &data->screen, 0 );
reader_repaint();
break;