Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-1-5]: src/libexec/telnetd Pull down (revert) revision 1.19 (reque...



details:   https://anonhg.NetBSD.org/src/rev/d90ffd41c2e9
branches:  netbsd-1-5
changeset: 490359:d90ffd41c2e9
user:      he <he%NetBSD.org@localhost>
date:      Fri Dec 15 00:37:19 2000 +0000

description:
Pull down (revert) revision 1.19 (requested by tv):
  1.19 would require a header file update, and is not really
  required.

diffstat:

 libexec/telnetd/sys_term.c |  21 ++++++++++-----------
 1 files changed, 10 insertions(+), 11 deletions(-)

diffs (67 lines):

diff -r 33d043e98315 -r d90ffd41c2e9 libexec/telnetd/sys_term.c
--- a/libexec/telnetd/sys_term.c        Fri Dec 15 00:26:34 2000 +0000
+++ b/libexec/telnetd/sys_term.c        Fri Dec 15 00:37:19 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sys_term.c,v 1.18.4.1 2000/12/14 23:02:53 he Exp $     */
+/*     $NetBSD: sys_term.c,v 1.18.4.2 2000/12/15 00:37:19 he Exp $     */
 
 /*
  * Copyright (c) 1989, 1993
@@ -38,7 +38,7 @@
 #if 0
 static char sccsid[] = "@(#)sys_term.c 8.4+1 (Berkeley) 5/30/95";
 #else
-__RCSID("$NetBSD: sys_term.c,v 1.18.4.1 2000/12/14 23:02:53 he Exp $");
+__RCSID("$NetBSD: sys_term.c,v 1.18.4.2 2000/12/15 00:37:19 he Exp $");
 #endif
 #endif /* not lint */
 
@@ -482,13 +482,13 @@
  * Returns the file descriptor of the opened pty.
  */
 #ifndef        __GNUC__
-char *line = NULL16STR;
+char *line = "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0";
 #else
-static char Xline[] = NULL16STR;
+static char Xline[] = "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0";
 char *line = Xline;
 #endif
 #ifdef CRAY
-char *myline = NULL16STR;
+char *myline = "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0";
 #endif /* CRAY */
 
 #ifdef OPENPTY_PTY
@@ -522,7 +522,7 @@
        if (p > 0) {
                grantpt(p);
                unlockpt(p);
-               (void)strlcpy(line, ptsname(p), sizeof(NULL16STR));
+               strcpy(line, ptsname(p));
                return(p);
        }
 
@@ -1601,7 +1601,7 @@
 #endif
 #ifdef SOLARIS
        char *term;
-       char termnamebuf[64];
+       char termbuf[64];
 #endif
 
 #ifdef UTMPX
@@ -1655,10 +1655,9 @@
                if (term == NULL || term[0] == 0) {
                        term = "-";
                } else {
-                       (void)strcpy(termnamebuf, "TERM=");
-                       (void)strlcpy(&termnamebuf[5], term,
-                           sizeof(termnamebuf) - 6);
-                       term = termnamebuf;
+                       strcpy(termbuf, "TERM=");
+                       strncat(termbuf, term, sizeof(termbuf) - 6);
+                       term = termbuf;
                }
                argv = addarg(argv, term);
 #endif



Home | Main Index | Thread Index | Old Index