summaryrefslogtreecommitdiff
path: root/term/main.c
diff options
context:
space:
mode:
authorMarcus Brinkmann <marcus@gnu.org>2002-03-05 02:17:04 +0000
committerMarcus Brinkmann <marcus@gnu.org>2002-03-05 02:17:04 +0000
commit1536fb3ea57668f41c8c160288b3daeab2163639 (patch)
treee9b2ec8c65756107dda79b7cad91f3a8fade4fbe /term/main.c
parent7c66508fb414b4d9271e0772c67d4e6383d912e2 (diff)
2002-03-05 Marcus Brinkmann <marcus@gnu.org>
* main.c (main): Use memset instead bzero. Fix error message, and formatting of some comments. * ptyio.c (pty_io_read): Use memcpy instead bcopy. * users.c (S_tioctl_tiocflush): Ignore error by bottom handler's notice_input_flushed. * users.c (set_state): Likewise. If bottom handler's set_bits fails, don't adjust terminal state but return success anyway.
Diffstat (limited to 'term/main.c')
-rw-r--r--term/main.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/term/main.c b/term/main.c
index e56ed73f..769a8114 100644
--- a/term/main.c
+++ b/term/main.c
@@ -1,4 +1,4 @@
-/*
+/* main.c - A translator that emulates a terminal.
Copyright (C) 1995, 1996, 1997, 2000, 2002 Free Software Foundation, Inc.
Written by Michael I. Bushnell, p/BSG.
@@ -84,8 +84,8 @@ parse_opt (int opt, char *arg, struct argp_state *state)
rdev = strtoul (start, &end, 0);
if (*end == ',')
- /* MAJOR,MINOR form */
{
+ /* MAJOR,MINOR form. */
start = end;
rdev = (rdev << 8) + strtoul (start, &end, 0);
}
@@ -206,7 +206,7 @@ main (int argc, char **argv)
default:
/* Should not happen. */
- fprintf (stderr, "Unknown terminal type is unknown.\n");
+ fprintf (stderr, "Unknown terminal type\n");
exit (1);
}
@@ -218,7 +218,7 @@ main (int argc, char **argv)
exit (1);
}
- /* Set our node */
+ /* Set our node. */
errno = trivfs_startup (bootstrap, 0,
ourcntlclass, term_bucket, ourclass, term_bucket,
ourcntl);
@@ -232,7 +232,7 @@ main (int argc, char **argv)
the hook to store the nodename. */
(*ourcntl)->hook = tty_name;
- /* Set peer */
+ /* Set peer. */
if (peerclass)
{
char *peer_name = tty_arg;
@@ -262,7 +262,7 @@ main (int argc, char **argv)
ports_port_deref (*peercntl);
}
- bzero (&termstate, sizeof (termstate));
+ memset (&termstate, 0, sizeof (termstate));
termflags = NO_CARRIER | NO_OWNER;
mutex_init (&global_lock);
@@ -301,7 +301,7 @@ main (int argc, char **argv)
condition_implies (inputq->wait, &select_alert);
condition_implies (outputq->wait, &select_alert);
- /* Launch */
+ /* Launch. */
ports_manage_port_operations_multithread (term_bucket, demuxer, 0, 0, 0);
return 0;