summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormarkm <markm@FreeBSD.org>2003-05-11 18:27:49 +0000
committermarkm <markm@FreeBSD.org>2003-05-11 18:27:49 +0000
commitfc4822f39a8e7e97128395b08fe26a085b317c0c (patch)
tree3849a7bccf9eaf054f46735c89aa776fbbe0a94b
parent141dcc06d33af21b6ab2f50416283892a6c6ed75 (diff)
downloadFreeBSD-src-fc4822f39a8e7e97128395b08fe26a085b317c0c.zip
FreeBSD-src-fc4822f39a8e7e97128395b08fe26a085b317c0c.tar.gz
Mrege from crypto telnet with "make unifdef". This gets a bunch of
$FreeBSD$ tags and some debug variable safety belts.
-rw-r--r--libexec/telnetd/global.c8
-rw-r--r--libexec/telnetd/slc.c8
-rw-r--r--libexec/telnetd/state.c8
-rw-r--r--libexec/telnetd/sys_term.c8
-rw-r--r--libexec/telnetd/telnetd.c10
-rw-r--r--libexec/telnetd/termstat.c8
-rw-r--r--libexec/telnetd/utility.c8
-rw-r--r--usr.bin/telnet/commands.c16
-rw-r--r--usr.bin/telnet/externs.h2
-rw-r--r--usr.bin/telnet/main.c10
-rw-r--r--usr.bin/telnet/network.c8
-rw-r--r--usr.bin/telnet/ring.c8
-rw-r--r--usr.bin/telnet/sys_bsd.c12
-rw-r--r--usr.bin/telnet/telnet.c10
-rw-r--r--usr.bin/telnet/terminal.c8
-rw-r--r--usr.bin/telnet/utilities.c8
16 files changed, 70 insertions, 70 deletions
diff --git a/libexec/telnetd/global.c b/libexec/telnetd/global.c
index 0cf95db..2ed82d0 100644
--- a/libexec/telnetd/global.c
+++ b/libexec/telnetd/global.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#ifndef lint
#if 0
+#ifndef lint
static const char sccsid[] = "@(#)global.c 8.1 (Berkeley) 6/4/93";
-#endif
-static const char rcsid[] =
- "$FreeBSD$";
#endif /* not lint */
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
/*
* Allocate global variables. We do this
diff --git a/libexec/telnetd/slc.c b/libexec/telnetd/slc.c
index d4eee1a..ad03441 100644
--- a/libexec/telnetd/slc.c
+++ b/libexec/telnetd/slc.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)slc.c 8.2 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include "telnetd.h"
diff --git a/libexec/telnetd/state.c b/libexec/telnetd/state.c
index 412fd94..7b733e4 100644
--- a/libexec/telnetd/state.c
+++ b/libexec/telnetd/state.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)state.c 8.5 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include <stdarg.h>
#include "telnetd.h"
diff --git a/libexec/telnetd/sys_term.c b/libexec/telnetd/sys_term.c
index 17686b3..e0525d6 100644
--- a/libexec/telnetd/sys_term.c
+++ b/libexec/telnetd/sys_term.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)sys_term.c 8.4+1 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include <sys/types.h>
#include <sys/tty.h>
diff --git a/libexec/telnetd/telnetd.c b/libexec/telnetd/telnetd.c
index 7532865..042fea5 100644
--- a/libexec/telnetd/telnetd.c
+++ b/libexec/telnetd/telnetd.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)telnetd.c 8.4 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include "telnetd.h"
#include "pathnames.h"
@@ -71,7 +71,7 @@ int terminaltypeok(char *);
int hostinfo = 1; /* do we print login banner? */
-int debug = 0;
+static int debug = 0;
int keepalive = 1;
const char *altlogin;
diff --git a/libexec/telnetd/termstat.c b/libexec/telnetd/termstat.c
index 14719a2..8d8257d 100644
--- a/libexec/telnetd/termstat.c
+++ b/libexec/telnetd/termstat.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)termstat.c 8.2 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include "telnetd.h"
diff --git a/libexec/telnetd/utility.c b/libexec/telnetd/utility.c
index c835269..042b248 100644
--- a/libexec/telnetd/utility.c
+++ b/libexec/telnetd/utility.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#ifndef lint
#if 0
+#ifndef lint
static const char sccsid[] = "@(#)utility.c 8.4 (Berkeley) 5/30/95";
-#endif
-static const char rcsid[] =
- "$FreeBSD$";
#endif /* not lint */
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#ifdef __FreeBSD__
#include <locale.h>
diff --git a/usr.bin/telnet/commands.c b/usr.bin/telnet/commands.c
index e0c5b62..489481f 100644
--- a/usr.bin/telnet/commands.c
+++ b/usr.bin/telnet/commands.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)commands.c 8.4 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include <sys/param.h>
#include <sys/un.h>
@@ -517,11 +517,11 @@ togdebug(void)
{
#ifndef NOT43
if (net > 0 &&
- (SetSockOpt(net, SOL_SOCKET, SO_DEBUG, debug)) < 0) {
+ (SetSockOpt(net, SOL_SOCKET, SO_DEBUG, telnet_debug)) < 0) {
perror("setsockopt (SO_DEBUG)");
}
#else /* NOT43 */
- if (debug) {
+ if (telnet_debug) {
if (net > 0 && SetSockOpt(net, SOL_SOCKET, SO_DEBUG, 1) < 0)
perror("setsockopt (SO_DEBUG)");
} else
@@ -692,7 +692,7 @@ static struct togglelist Togglelist[] = {
{ "debug",
"debugging",
(int (*)(int))togdebug,
- &debug,
+ &telnet_debug,
"turn on socket level debugging" },
{ "netdata",
"printing of hexadecimal network data (debugging)",
@@ -2146,7 +2146,7 @@ tn(int argc, char *argv[])
}
#endif /* defined(IPPROTO_IP) && defined(IP_TOS) */
- if (debug && SetSockOpt(net, SOL_SOCKET, SO_DEBUG, 1) < 0) {
+ if (telnet_debug && SetSockOpt(net, SOL_SOCKET, SO_DEBUG, 1) < 0) {
perror("setsockopt (SO_DEBUG)");
}
diff --git a/usr.bin/telnet/externs.h b/usr.bin/telnet/externs.h
index 1129817..b4fd327 100644
--- a/usr.bin/telnet/externs.h
+++ b/usr.bin/telnet/externs.h
@@ -127,7 +127,7 @@ extern int
netdata, /* Print out network data flow */
prettydump, /* Print "netdata" output in user readable format */
termdata, /* Print out terminal data flow */
- debug, /* Debug level */
+ telnet_debug, /* Debug level */
doaddrlookup, /* do a reverse lookup? */
clienteof; /* Client received EOF */
diff --git a/usr.bin/telnet/main.c b/usr.bin/telnet/main.c
index 676f13f..e007348 100644
--- a/usr.bin/telnet/main.c
+++ b/usr.bin/telnet/main.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)main.c 8.3 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include <sys/types.h>
#include <sys/socket.h>
@@ -180,7 +180,7 @@ main(int argc, char *argv[])
skiprc = 1;
break;
case 'd':
- debug = 1;
+ telnet_debug = 1;
break;
case 'e':
set_escape_char(optarg);
diff --git a/usr.bin/telnet/network.c b/usr.bin/telnet/network.c
index b93f825..cdcd419 100644
--- a/usr.bin/telnet/network.c
+++ b/usr.bin/telnet/network.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)network.c 8.2 (Berkeley) 12/15/93";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include <sys/types.h>
#include <sys/socket.h>
diff --git a/usr.bin/telnet/ring.c b/usr.bin/telnet/ring.c
index ac415a9..b6e2bea 100644
--- a/usr.bin/telnet/ring.c
+++ b/usr.bin/telnet/ring.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)ring.c 8.2 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
/*
* This defines a structure for a ring buffer.
diff --git a/usr.bin/telnet/sys_bsd.c b/usr.bin/telnet/sys_bsd.c
index 5d931bf..45ef1e2 100644
--- a/usr.bin/telnet/sys_bsd.c
+++ b/usr.bin/telnet/sys_bsd.c
@@ -31,15 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-#include <stdlib.h>
-#include <err.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)sys_bsd.c 8.4 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
/*
* The following routines try to encapsulate what is system dependent
@@ -49,9 +47,11 @@ static const char sccsid[] = "@(#)sys_bsd.c 8.4 (Berkeley) 5/30/95";
#include <sys/param.h>
#include <sys/socket.h>
#include <sys/time.h>
+#include <err.h>
#include <errno.h>
#include <fcntl.h>
#include <signal.h>
+#include <stdlib.h>
#include <unistd.h>
#include <arpa/telnet.h>
diff --git a/usr.bin/telnet/telnet.c b/usr.bin/telnet/telnet.c
index 27aeaa9..75c27a5 100644
--- a/usr.bin/telnet/telnet.c
+++ b/usr.bin/telnet/telnet.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)telnet.c 8.4 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include <sys/types.h>
@@ -89,7 +89,7 @@ int
connected,
showoptions,
ISend, /* trying to send network data in */
- debug = 0,
+ telnet_debug = 0,
crmod,
netdata, /* Print out network data flow */
crlf, /* Should '\r' be mapped to <CR><LF> (or <CR><NUL>)? */
diff --git a/usr.bin/telnet/terminal.c b/usr.bin/telnet/terminal.c
index b6e4a47..bea4e4d 100644
--- a/usr.bin/telnet/terminal.c
+++ b/usr.bin/telnet/terminal.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)terminal.c 8.2 (Berkeley) 2/16/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include <arpa/telnet.h>
#include <sys/types.h>
diff --git a/usr.bin/telnet/utilities.c b/usr.bin/telnet/utilities.c
index 4a51966..d1eb8a8 100644
--- a/usr.bin/telnet/utilities.c
+++ b/usr.bin/telnet/utilities.c
@@ -31,13 +31,13 @@
* SUCH DAMAGE.
*/
-#include <sys/cdefs.h>
-
-__FBSDID("$FreeBSD$");
-
+#if 0
#ifndef lint
static const char sccsid[] = "@(#)utilities.c 8.3 (Berkeley) 5/30/95";
#endif
+#endif
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#define TELOPTS
#define TELCMDS
OpenPOWER on IntegriCloud