diff options
Diffstat (limited to 'misc/getttyent.c')
-rw-r--r-- | misc/getttyent.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/misc/getttyent.c b/misc/getttyent.c index dc4b9fa..f73cb79 100644 --- a/misc/getttyent.c +++ b/misc/getttyent.c @@ -55,7 +55,7 @@ getttynam(tty) register struct ttyent *t; setttyent(); - while (t = getttyent()) + while ((t = getttyent())) if (!strcmp(tty, t->ty_name)) break; endttyent(); @@ -131,7 +131,7 @@ getttyent() tty.ty_comment = p; if (*p == 0) tty.ty_comment = 0; - if (p = index(p, '\n')) + if ((p = index(p, '\n'))) *p = '\0'; return (&tty); } @@ -193,7 +193,7 @@ setttyent() if (tf) { (void)rewind(tf); return (1); - } else if (tf = fopen(_PATH_TTYS, "r")) + } else if ((tf = fopen(_PATH_TTYS, "r"))) return (1); return (0); } |