Module Name: src
Committed By: joerg
Date: Mon Aug 29 20:41:07 UTC 2011
Modified Files:
src/libexec/ftpd: extern.h ftpd.c
src/libexec/getNAME: getNAME.c
src/libexec/identd: identd.c
src/libexec/rpc.rstatd: rstatd.c
src/libexec/rpc.rwalld: rwalld.c
src/libexec/rpc.sprayd: sprayd.c
src/libexec/tftpd: tftpd.c
Log Message:
Use __dead
To generate a diff of this commit:
cvs rdiff -u -r1.61 -r1.62 src/libexec/ftpd/extern.h
cvs rdiff -u -r1.194 -r1.195 src/libexec/ftpd/ftpd.c
cvs rdiff -u -r1.26 -r1.27 src/libexec/getNAME/getNAME.c
cvs rdiff -u -r1.32 -r1.33 src/libexec/identd/identd.c
cvs rdiff -u -r1.14 -r1.15 src/libexec/rpc.rstatd/rstatd.c
cvs rdiff -u -r1.20 -r1.21 src/libexec/rpc.rwalld/rwalld.c
cvs rdiff -u -r1.15 -r1.16 src/libexec/rpc.sprayd/sprayd.c
cvs rdiff -u -r1.38 -r1.39 src/libexec/tftpd/tftpd.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/libexec/ftpd/extern.h
diff -u src/libexec/ftpd/extern.h:1.61 src/libexec/ftpd/extern.h:1.62
--- src/libexec/ftpd/extern.h:1.61 Mon Jul 13 19:05:40 2009
+++ src/libexec/ftpd/extern.h Mon Aug 29 20:41:06 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: extern.h,v 1.61 2009/07/13 19:05:40 roy Exp $ */
+/* $NetBSD: extern.h,v 1.62 2011/08/29 20:41:06 joerg Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -124,8 +124,8 @@
void delete(const char *);
int display_file(const char *, int);
const char **do_conversion(const char *);
-void dologout(int);
-void fatal(const char *);
+__dead void dologout(int);
+__dead void fatal(const char *);
void feat(void);
void format_path(char *, const char *);
int ftpd_pclose(FILE *);
Index: src/libexec/ftpd/ftpd.c
diff -u src/libexec/ftpd/ftpd.c:1.194 src/libexec/ftpd/ftpd.c:1.195
--- src/libexec/ftpd/ftpd.c:1.194 Mon Jul 13 19:05:40 2009
+++ src/libexec/ftpd/ftpd.c Mon Aug 29 20:41:06 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: ftpd.c,v 1.194 2009/07/13 19:05:40 roy Exp $ */
+/* $NetBSD: ftpd.c,v 1.195 2011/08/29 20:41:06 joerg Exp $ */
/*
* Copyright (c) 1997-2009 The NetBSD Foundation, Inc.
@@ -97,7 +97,7 @@
#if 0
static char sccsid[] = "@(#)ftpd.c 8.5 (Berkeley) 4/28/95";
#else
-__RCSID("$NetBSD: ftpd.c,v 1.194 2009/07/13 19:05:40 roy Exp $");
+__RCSID("$NetBSD: ftpd.c,v 1.195 2011/08/29 20:41:06 joerg Exp $");
#endif
#endif /* not lint */
@@ -249,9 +249,9 @@
static void login_utmp(const char *, const char *, const char *,
struct sockinet *);
static void logremotehost(struct sockinet *);
-static void lostconn(int);
-static void toolong(int);
-static void sigquit(int);
+__dead static void lostconn(int);
+__dead static void toolong(int);
+__dead static void sigquit(int);
static void sigurg(int);
static int handleoobcmd(void);
static int receive_data(FILE *, FILE *);
Index: src/libexec/getNAME/getNAME.c
diff -u src/libexec/getNAME/getNAME.c:1.26 src/libexec/getNAME/getNAME.c:1.27
--- src/libexec/getNAME/getNAME.c:1.26 Sun Jul 20 01:09:07 2008
+++ src/libexec/getNAME/getNAME.c Mon Aug 29 20:41:06 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: getNAME.c,v 1.26 2008/07/20 01:09:07 lukem Exp $ */
+/* $NetBSD: getNAME.c,v 1.27 2011/08/29 20:41:06 joerg Exp $ */
/*-
* Copyright (c) 1997, Christos Zoulas. All rights reserved.
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)getNAME.c 8.1 (Berkeley) 6/30/93";
#else
-__RCSID("$NetBSD: getNAME.c,v 1.26 2008/07/20 01:09:07 lukem Exp $");
+__RCSID("$NetBSD: getNAME.c,v 1.27 2011/08/29 20:41:06 joerg Exp $");
#endif
#endif /* not lint */
@@ -76,7 +76,7 @@
static void remquote(char *, size_t *);
static void fixxref(char *, size_t *);
static void split(char *, char *);
-static void usage(void);
+__dead static void usage(void);
int main(int, char *[]);
Index: src/libexec/identd/identd.c
diff -u src/libexec/identd/identd.c:1.32 src/libexec/identd/identd.c:1.33
--- src/libexec/identd/identd.c:1.32 Sun Jan 18 00:37:53 2009
+++ src/libexec/identd/identd.c Mon Aug 29 20:41:06 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: identd.c,v 1.32 2009/01/18 00:37:53 lukem Exp $ */
+/* $NetBSD: identd.c,v 1.33 2011/08/29 20:41:06 joerg Exp $ */
/*
* identd.c - TCP/IP Ident protocol server.
@@ -8,7 +8,7 @@
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: identd.c,v 1.32 2009/01/18 00:37:53 lukem Exp $");
+__RCSID("$NetBSD: identd.c,v 1.33 2011/08/29 20:41:06 joerg Exp $");
#include <sys/param.h>
#include <sys/socket.h>
@@ -61,9 +61,9 @@
static int check_userident(const char *, char *, size_t);
static void random_string(char *, size_t);
static int change_format(const char *, struct passwd *, char *, size_t);
-static void timeout_handler(int);
-static void fatal(const char *);
-static void die(const char *, ...);
+__dead static void timeout_handler(int);
+__dead static void fatal(const char *);
+__dead static void die(const char *, ...);
static int bflag, eflag, fflag, iflag, Iflag;
static int lflag, Lflag, nflag, Nflag, rflag;
Index: src/libexec/rpc.rstatd/rstatd.c
diff -u src/libexec/rpc.rstatd/rstatd.c:1.14 src/libexec/rpc.rstatd/rstatd.c:1.15
--- src/libexec/rpc.rstatd/rstatd.c:1.14 Tue May 9 20:18:07 2006
+++ src/libexec/rpc.rstatd/rstatd.c Mon Aug 29 20:41:06 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: rstatd.c,v 1.14 2006/05/09 20:18:07 mrg Exp $ */
+/* $NetBSD: rstatd.c,v 1.15 2011/08/29 20:41:06 joerg Exp $ */
/*-
* Copyright (c) 1993, John Brezak
@@ -35,7 +35,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: rstatd.c,v 1.14 2006/05/09 20:18:07 mrg Exp $");
+__RCSID("$NetBSD: rstatd.c,v 1.15 2011/08/29 20:41:06 joerg Exp $");
#endif /* not lint */
#include <sys/types.h>
@@ -50,13 +50,12 @@
#include <rpcsvc/rstat.h>
extern void rstat_service(struct svc_req *, SVCXPRT *);
-void cleanup(int);
-int main(int, char *[]);
+__dead static void cleanup(int);
int from_inetd = 1; /* started from inetd ? */
int closedown = 20; /* how long to wait before going dormant */
-void
+static void
cleanup(int dummy)
{
(void) rpcb_unset(RSTATPROG, RSTATVERS_TIME, NULL);
Index: src/libexec/rpc.rwalld/rwalld.c
diff -u src/libexec/rpc.rwalld/rwalld.c:1.20 src/libexec/rpc.rwalld/rwalld.c:1.21
--- src/libexec/rpc.rwalld/rwalld.c:1.20 Tue May 9 20:18:07 2006
+++ src/libexec/rpc.rwalld/rwalld.c Mon Aug 29 20:41:06 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: rwalld.c,v 1.20 2006/05/09 20:18:07 mrg Exp $ */
+/* $NetBSD: rwalld.c,v 1.21 2011/08/29 20:41:06 joerg Exp $ */
/*
* Copyright (c) 1993 Christopher G. Demetriou
@@ -36,7 +36,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: rwalld.c,v 1.20 2006/05/09 20:18:07 mrg Exp $");
+__RCSID("$NetBSD: rwalld.c,v 1.21 2011/08/29 20:41:06 joerg Exp $");
#endif /* not lint */
#include <unistd.h>
@@ -64,9 +64,7 @@
static void cleanup(int);
static void wallprog_1(struct svc_req *, SVCXPRT *);
-int main(int, char *[]);
-
-static void
+__dead static void
cleanup(int n)
{
Index: src/libexec/rpc.sprayd/sprayd.c
diff -u src/libexec/rpc.sprayd/sprayd.c:1.15 src/libexec/rpc.sprayd/sprayd.c:1.16
--- src/libexec/rpc.sprayd/sprayd.c:1.15 Wed Oct 21 01:07:46 2009
+++ src/libexec/rpc.sprayd/sprayd.c Mon Aug 29 20:41:06 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: sprayd.c,v 1.15 2009/10/21 01:07:46 snj Exp $ */
+/* $NetBSD: sprayd.c,v 1.16 2011/08/29 20:41:06 joerg Exp $ */
/*
* Copyright (c) 1994 Christos Zoulas
@@ -27,7 +27,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: sprayd.c,v 1.15 2009/10/21 01:07:46 snj Exp $");
+__RCSID("$NetBSD: sprayd.c,v 1.16 2011/08/29 20:41:06 joerg Exp $");
#endif /* not lint */
#include <stdio.h>
@@ -40,12 +40,10 @@
#include <rpc/rpc.h>
#include <rpcsvc/spray.h>
-static void cleanup(int);
-static void die(int);
+__dead static void cleanup(int);
+__dead static void die(int);
static void spray_service(struct svc_req *, SVCXPRT *);
-int main(int, char *[]);
-
static int from_inetd = 1;
#define TIMEOUT 120
Index: src/libexec/tftpd/tftpd.c
diff -u src/libexec/tftpd/tftpd.c:1.38 src/libexec/tftpd/tftpd.c:1.39
--- src/libexec/tftpd/tftpd.c:1.38 Thu Apr 29 20:13:46 2010
+++ src/libexec/tftpd/tftpd.c Mon Aug 29 20:41:07 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: tftpd.c,v 1.38 2010/04/29 20:13:46 hubertf Exp $ */
+/* $NetBSD: tftpd.c,v 1.39 2011/08/29 20:41:07 joerg Exp $ */
/*
* Copyright (c) 1983, 1993
@@ -36,7 +36,7 @@
#if 0
static char sccsid[] = "@(#)tftpd.c 8.1 (Berkeley) 6/4/93";
#else
-__RCSID("$NetBSD: tftpd.c,v 1.38 2010/04/29 20:13:46 hubertf Exp $");
+__RCSID("$NetBSD: tftpd.c,v 1.39 2011/08/29 20:41:07 joerg Exp $");
#endif
#endif /* not lint */
@@ -115,13 +115,13 @@
static const char *errtomsg(int);
static void nak(int);
-static void tftp(struct tftphdr *, int);
-static void usage(void) __attribute__((__noreturn__));
+__dead static void tftp(struct tftphdr *, int);
+__dead static void usage(void);
static char *verifyhost(struct sockaddr *);
-static void justquit(int);
+__dead static void justquit(int);
static void recvfile(struct formats *, int, int);
static void sendfile(struct formats *, int, int);
-static void timer(int);
+__dead static void timer(int);
static const char *opcode(int);
static int validate_access(char **, int);