summaryrefslogtreecommitdiff
path: root/src/sys/con_tty.c
diff options
context:
space:
mode:
authorTim Angus <tim@ngus.net>2009-10-03 12:31:59 +0000
committerTim Angus <tim@ngus.net>2013-01-03 00:16:03 +0000
commit304d4258d3a49488f570b8ad71931faa7e5d40ba (patch)
treebf9ec15bd9154305ff9fab2943b3daf25024f8a5 /src/sys/con_tty.c
parent6e90e4e7861f5cb354487d1fe0f1fd06c385308e (diff)
* Merge ioq3-r1498, by popular demand
Diffstat (limited to 'src/sys/con_tty.c')
-rw-r--r--src/sys/con_tty.c20
1 files changed, 12 insertions, 8 deletions
diff --git a/src/sys/con_tty.c b/src/sys/con_tty.c
index 687d1dd4..cdd686a1 100644
--- a/src/sys/con_tty.c
+++ b/src/sys/con_tty.c
@@ -87,12 +87,14 @@ send "\b \b"
static void CON_Back( void )
{
char key;
+ size_t size;
+
key = '\b';
- write(1, &key, 1);
+ size = write(1, &key, 1);
key = ' ';
- write(1, &key, 1);
+ size = write(1, &key, 1);
key = '\b';
- write(1, &key, 1);
+ size = write(1, &key, 1);
}
/*
@@ -143,12 +145,13 @@ static void CON_Show( void )
ttycon_hide--;
if (ttycon_hide == 0)
{
- write( 1, "]", 1 );
+ size_t size;
+ size = write( 1, "]", 1 );
if (TTY_con.cursor)
{
for (i=0; i<TTY_con.cursor; i++)
{
- write(1, TTY_con.buffer+i, 1);
+ size = write(1, TTY_con.buffer+i, 1);
}
}
}
@@ -308,6 +311,7 @@ char *CON_Input( void )
int avail;
char key;
field_t *history;
+ size_t size;
if( ttycon_on )
{
@@ -337,8 +341,8 @@ char *CON_Input( void )
strcpy(text, TTY_con.buffer);
Field_Clear(&TTY_con);
key = '\n';
- write(1, &key, 1);
- write( 1, "]", 1 );
+ size = write(1, &key, 1);
+ size = write( 1, "]", 1 );
return text;
}
if (key == '\t')
@@ -400,7 +404,7 @@ char *CON_Input( void )
TTY_con.buffer[TTY_con.cursor] = key;
TTY_con.cursor++;
// print the current line (this is differential)
- write(1, &key, 1);
+ size = write(1, &key, 1);
}
return NULL;