Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.sbin/sliplogin static + ANSIfy + __dead
details: https://anonhg.NetBSD.org/src/rev/ff70562c0301
branches: trunk
changeset: 769060:ff70562c0301
user: joerg <joerg%NetBSD.org@localhost>
date: Tue Aug 30 20:42:22 2011 +0000
description:
static + ANSIfy + __dead
diffstat:
usr.sbin/sliplogin/sliplogin.c | 42 ++++++++++++++++++------------------------
1 files changed, 18 insertions(+), 24 deletions(-)
diffs (86 lines):
diff -r b6af76500b7f -r ff70562c0301 usr.sbin/sliplogin/sliplogin.c
--- a/usr.sbin/sliplogin/sliplogin.c Tue Aug 30 20:33:30 2011 +0000
+++ b/usr.sbin/sliplogin/sliplogin.c Tue Aug 30 20:42:22 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sliplogin.c,v 1.22 2008/07/21 13:36:59 lukem Exp $ */
+/* $NetBSD: sliplogin.c,v 1.23 2011/08/30 20:42:22 joerg Exp $ */
/*-
* Copyright (c) 1990, 1993
@@ -39,7 +39,7 @@
#if 0
static char sccsid[] = "@(#)sliplogin.c 8.2 (Berkeley) 2/1/94";
#else
-__RCSID("$NetBSD: sliplogin.c,v 1.22 2008/07/21 13:36:59 lukem Exp $");
+__RCSID("$NetBSD: sliplogin.c,v 1.23 2011/08/30 20:42:22 joerg Exp $");
#endif
#endif /* not lint */
@@ -100,21 +100,19 @@
#include "pathnames.h"
-int unit;
-int speed;
-int uid;
-char loginargs[BUFSIZ];
-char loginfile[MAXPATHLEN];
-char loginname[BUFSIZ];
+static int unit;
+static int speed;
+static int uid;
+static char loginargs[BUFSIZ];
+static char loginfile[MAXPATHLEN];
+static char loginname[BUFSIZ];
-void findid __P((char *));
-void hup_handler __P((int));
-int main __P((int, char **));
-const char *sigstr __P((int));
+static void findid(const char *);
+__dead static void hup_handler(int);
+static const char *sigstr(int);
-void
-findid(name)
- char *name;
+static void
+findid(const char *name)
{
FILE *fp;
static char slopt[5][16];
@@ -168,9 +166,8 @@
/* NOTREACHED */
}
-const char *
-sigstr(s)
- int s;
+static const char *
+sigstr(int s)
{
if (s > 0 && s < NSIG)
@@ -183,9 +180,8 @@
}
}
-void
-hup_handler(s)
- int s;
+static void
+hup_handler(int s)
{
char logoutfile[MAXPATHLEN];
@@ -208,9 +204,7 @@
}
int
-main(argc, argv)
- int argc;
- char *argv[];
+main(int argc, char *argv[])
{
int fd, s, ldisc, odisc;
char *name;
Home |
Main Index |
Thread Index |
Old Index