Module Name: src Committed By: joerg Date: Thu Mar 22 22:59:43 UTC 2012
Modified Files: src/dist/bzip2: bzlib_private.h src/lib/csu/common: crt0-common.c src/lib/libskey: skeysubr.c src/lib/libwrap: options.c rfc931.c shell_cmd.c tcpd.h Log Message: Add some more __dead as exposed by the recent WARN bumps. To generate a diff of this commit: cvs rdiff -u -r1.1.1.3 -r1.2 src/dist/bzip2/bzlib_private.h cvs rdiff -u -r1.7 -r1.8 src/lib/csu/common/crt0-common.c cvs rdiff -u -r1.27 -r1.28 src/lib/libskey/skeysubr.c cvs rdiff -u -r1.15 -r1.16 src/lib/libwrap/options.c cvs rdiff -u -r1.9 -r1.10 src/lib/libwrap/rfc931.c cvs rdiff -u -r1.6 -r1.7 src/lib/libwrap/shell_cmd.c cvs rdiff -u -r1.13 -r1.14 src/lib/libwrap/tcpd.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/dist/bzip2/bzlib_private.h diff -u src/dist/bzip2/bzlib_private.h:1.1.1.3 src/dist/bzip2/bzlib_private.h:1.2 --- src/dist/bzip2/bzlib_private.h:1.1.1.3 Tue Mar 18 14:41:47 2008 +++ src/dist/bzip2/bzlib_private.h Thu Mar 22 22:59:43 2012 @@ -55,7 +55,7 @@ typedef unsigned short UInt16; #ifndef BZ_NO_STDIO -extern void BZ2_bz__AssertH__fail ( int errcode ); +__dead void BZ2_bz__AssertH__fail ( int errcode ); #define AssertH(cond,errcode) \ { if (!(cond)) BZ2_bz__AssertH__fail ( errcode ); } Index: src/lib/csu/common/crt0-common.c diff -u src/lib/csu/common/crt0-common.c:1.7 src/lib/csu/common/crt0-common.c:1.8 --- src/lib/csu/common/crt0-common.c:1.7 Thu Jun 30 20:07:35 2011 +++ src/lib/csu/common/crt0-common.c Thu Mar 22 22:59:43 2012 @@ -1,4 +1,4 @@ -/* $NetBSD: crt0-common.c,v 1.7 2011/06/30 20:07:35 matt Exp $ */ +/* $NetBSD: crt0-common.c,v 1.8 2012/03/22 22:59:43 joerg Exp $ */ /* * Copyright (c) 1998 Christos Zoulas @@ -36,7 +36,7 @@ */ #include <sys/cdefs.h> -__RCSID("$NetBSD: crt0-common.c,v 1.7 2011/06/30 20:07:35 matt Exp $"); +__RCSID("$NetBSD: crt0-common.c,v 1.8 2012/03/22 22:59:43 joerg Exp $"); #include <sys/types.h> #include <sys/exec.h> @@ -74,7 +74,7 @@ struct ps_strings *__ps_strings = 0; static char empty_string[] = ""; char *__progname = empty_string; -__dso_hidden void ___start(void (*)(void), const Obj_Entry *, +__dead __dso_hidden void ___start(void (*)(void), const Obj_Entry *, struct ps_strings *); #define write(fd, s, n) __syscall(SYS_write, (fd), (s), (n)) Index: src/lib/libskey/skeysubr.c diff -u src/lib/libskey/skeysubr.c:1.27 src/lib/libskey/skeysubr.c:1.28 --- src/lib/libskey/skeysubr.c:1.27 Wed Mar 21 10:10:37 2012 +++ src/lib/libskey/skeysubr.c Thu Mar 22 22:59:43 2012 @@ -1,4 +1,4 @@ -/* $NetBSD: skeysubr.c,v 1.27 2012/03/21 10:10:37 matt Exp $ */ +/* $NetBSD: skeysubr.c,v 1.28 2012/03/22 22:59:43 joerg Exp $ */ /* S/KEY v1.1b (skeysubr.c) * @@ -15,7 +15,7 @@ */ #include <sys/cdefs.h> -__RCSID("$NetBSD: skeysubr.c,v 1.27 2012/03/21 10:10:37 matt Exp $"); +__RCSID("$NetBSD: skeysubr.c,v 1.28 2012/03/22 22:59:43 joerg Exp $"); #include <ctype.h> #include <stdio.h> @@ -46,7 +46,7 @@ static int keycrunch_sha1(char *, const /* static int keycrunch_rmd160(char *, const char *, const char *); */ static void lowcase(char *); static void skey_echo(int); -static void trapped(int); +static void trapped(int) __dead; static char *mkSeedPassword(const char *, const char *, size_t *); /* Current hash type (index into skey_hash_types array) */ Index: src/lib/libwrap/options.c diff -u src/lib/libwrap/options.c:1.15 src/lib/libwrap/options.c:1.16 --- src/lib/libwrap/options.c:1.15 Wed Mar 21 10:10:37 2012 +++ src/lib/libwrap/options.c Thu Mar 22 22:59:43 2012 @@ -1,4 +1,4 @@ -/* $NetBSD: options.c,v 1.15 2012/03/21 10:10:37 matt Exp $ */ +/* $NetBSD: options.c,v 1.16 2012/03/22 22:59:43 joerg Exp $ */ /* * General skeleton for adding options to the access control language. The @@ -35,7 +35,7 @@ #if 0 static char sccsid[] = "@(#) options.c 1.17 96/02/11 17:01:31"; #else -__RCSID("$NetBSD: options.c,v 1.15 2012/03/21 10:10:37 matt Exp $"); +__RCSID("$NetBSD: options.c,v 1.16 2012/03/22 22:59:43 joerg Exp $"); #endif #endif @@ -103,9 +103,9 @@ static void nice_option /* execute "ni (char *, struct request_info *); static void severity_option /* execute "severity value" */ (char *, struct request_info *); -static void allow_option /* execute "allow" option */ +__dead static void allow_option /* execute "allow" option */ (char *, struct request_info *); -static void deny_option /* execute "deny" option */ +__dead static void deny_option /* execute "deny" option */ (char *, struct request_info *); static void banners_option /* execute "banners path" option */ (char *, struct request_info *); Index: src/lib/libwrap/rfc931.c diff -u src/lib/libwrap/rfc931.c:1.9 src/lib/libwrap/rfc931.c:1.10 --- src/lib/libwrap/rfc931.c:1.9 Wed Mar 21 10:10:37 2012 +++ src/lib/libwrap/rfc931.c Thu Mar 22 22:59:43 2012 @@ -1,4 +1,4 @@ -/* $NetBSD: rfc931.c,v 1.9 2012/03/21 10:10:37 matt Exp $ */ +/* $NetBSD: rfc931.c,v 1.10 2012/03/22 22:59:43 joerg Exp $ */ /* * rfc931() speaks a common subset of the RFC 931, AUTH, TAP, IDENT and RFC @@ -16,7 +16,7 @@ #if 0 static char sccsid[] = "@(#) rfc931.c 1.10 95/01/02 16:11:34"; #else -__RCSID("$NetBSD: rfc931.c,v 1.9 2012/03/21 10:10:37 matt Exp $"); +__RCSID("$NetBSD: rfc931.c,v 1.10 2012/03/22 22:59:43 joerg Exp $"); #endif #endif @@ -45,7 +45,7 @@ int rfc931_timeout = RFC931_TIMEOUT; static jmp_buf timebuf; static FILE *fsocket(int, int, int); -static void timeout(int); +static void timeout(int) __dead; /* fsocket - open stdio stream on top of socket */ Index: src/lib/libwrap/shell_cmd.c diff -u src/lib/libwrap/shell_cmd.c:1.6 src/lib/libwrap/shell_cmd.c:1.7 --- src/lib/libwrap/shell_cmd.c:1.6 Wed Mar 21 10:10:37 2012 +++ src/lib/libwrap/shell_cmd.c Thu Mar 22 22:59:43 2012 @@ -1,4 +1,4 @@ -/* $NetBSD: shell_cmd.c,v 1.6 2012/03/21 10:10:37 matt Exp $ */ +/* $NetBSD: shell_cmd.c,v 1.7 2012/03/22 22:59:43 joerg Exp $ */ /* * shell_cmd() takes a shell command after %<character> substitutions. The @@ -15,7 +15,7 @@ #if 0 static char sccsid[] = "@(#) shell_cmd.c 1.5 94/12/28 17:42:44"; #else -__RCSID("$NetBSD: shell_cmd.c,v 1.6 2012/03/21 10:10:37 matt Exp $"); +__RCSID("$NetBSD: shell_cmd.c,v 1.7 2012/03/22 22:59:43 joerg Exp $"); #endif #endif @@ -38,7 +38,7 @@ __RCSID("$NetBSD: shell_cmd.c,v 1.6 2012 /* Forward declarations. */ -static void do_child __P((char *)); +static void do_child(char *) __dead; /* shell_cmd - execute shell command */ Index: src/lib/libwrap/tcpd.h diff -u src/lib/libwrap/tcpd.h:1.13 src/lib/libwrap/tcpd.h:1.14 --- src/lib/libwrap/tcpd.h:1.13 Wed Mar 21 10:10:37 2012 +++ src/lib/libwrap/tcpd.h Thu Mar 22 22:59:43 2012 @@ -1,4 +1,4 @@ -/* $NetBSD: tcpd.h,v 1.13 2012/03/21 10:10:37 matt Exp $ */ +/* $NetBSD: tcpd.h,v 1.14 2012/03/22 22:59:43 joerg Exp $ */ /* * @(#) tcpd.h 1.5 96/03/19 16:22:24 * @@ -79,9 +79,9 @@ extern char *percent_x /* do %<char> e (char *, int, char *, struct request_info *); extern void rfc931 /* client name from RFC 931 daemon */ (struct sockaddr *, struct sockaddr *, char *); -extern void clean_exit /* clean up and exit */ +__dead extern void clean_exit /* clean up and exit */ (struct request_info *); -extern void refuse /* clean up and exit */ +__dead extern void refuse /* clean up and exit */ (struct request_info *); extern char *xgets /* fgets() on steroids */ (char *, int, FILE *); @@ -167,12 +167,11 @@ extern void tli_host /* look up endpoi * everyone would have to include <setjmp.h>. */ -extern void tcpd_warn /* report problem and proceed */ - (const char *, ...) - __attribute__((__format__(__printf__, 1, 2))); -extern void tcpd_jump /* report problem and jump */ - (const char *, ...) - __attribute__((__format__(__printf__, 1, 2))); +/* Report problem and proceed */ +void tcpd_warn(const char *, ...) __printflike(1, 2); + +/* Report problem and jump */ +void tcpd_jump(const char *, ...) __dead __printflike(1, 2); __END_DECLS struct tcpd_context {