Source-Changes-HG archive

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

[src/trunk]: src Use __dead



details:   https://anonhg.NetBSD.org/src/rev/cdf947287137
branches:  trunk
changeset: 769624:cdf947287137
user:      joerg <joerg%NetBSD.org@localhost>
date:      Fri Sep 16 15:39:25 2011 +0000

description:
Use __dead

diffstat:

 distrib/utils/sysinst/aout2elf.c        |   4 ++--
 distrib/utils/sysinst/main.c            |   6 +++---
 usr.bin/dirname/dirname.c               |   6 +++---
 usr.bin/extattr/getextattr.c            |   4 ++--
 usr.bin/find/main.c                     |   7 +++----
 usr.bin/fsplit/fsplit.c                 |   4 ++--
 usr.bin/ftp/cmds.c                      |   6 +++---
 usr.bin/ftp/extern.h                    |  10 +++-------
 usr.bin/ftp/fetch.c                     |   8 ++++----
 usr.bin/ftp/ftp.c                       |  11 ++++++-----
 usr.bin/ftp/main.c                      |   6 +++---
 usr.bin/grep/grep.c                     |   6 +++---
 usr.bin/iconv/iconv.c                   |   6 +++---
 usr.bin/id/id.c                         |   4 ++--
 usr.bin/ktrace/ktrace.c                 |   9 ++++-----
 usr.bin/last/last.c                     |   8 +++-----
 usr.bin/last/want.c                     |   4 ++--
 usr.bin/leave/leave.c                   |  10 ++++------
 usr.bin/mail/cmd1.c                     |   6 +++---
 usr.bin/mail/collect.c                  |   6 +++---
 usr.bin/mail/lex.c                      |  10 +++++-----
 usr.bin/mail/tty.c                      |   6 +++---
 usr.bin/mkcsmapper/yacc.y               |   6 +++---
 usr.bin/mkesdb/yacc.y                   |   6 +++---
 usr.bin/netstat/if.c                    |   6 +++---
 usr.bin/netstat/main.c                  |   6 +++---
 usr.bin/newgrp/newgrp.c                 |   4 ++--
 usr.bin/passwd/extern.h                 |   4 ++--
 usr.bin/passwd/yp_passwd.c              |   6 +++---
 usr.bin/pathchk/pathchk.c               |   6 +++---
 usr.bin/progress/progress.c             |   7 +++----
 usr.bin/pwhash/pwhash.c                 |   6 +++---
 usr.bin/rev/rev.c                       |   7 +++----
 usr.bin/rpcinfo/rpcinfo.c               |   4 ++--
 usr.bin/rump_allserver/rump_allserver.c |   8 ++++----
 usr.bin/rump_dhcpclient/main.c          |   4 ++--
 usr.bin/rump_halt/rump.halt.c           |   6 +++---
 usr.bin/sdpquery/sdpquery.c             |   6 +++---
 usr.bin/shmif_dumpbus/shmif_dumpbus.c   |   4 ++--
 usr.bin/shuffle/shuffle.c               |   8 +++-----
 usr.bin/skey/skey.c                     |  11 +++++------
 usr.bin/sort/sort.c                     |   8 +++-----
 usr.bin/sort/sort.h                     |   4 ++--
 usr.bin/split/split.c                   |  11 +++++------
 usr.bin/tabs/tabs.c                     |   6 +++---
 usr.bin/tftp/main.c                     |   9 ++++-----
 usr.bin/tftp/tftp.c                     |   6 +++---
 usr.bin/unifdef/unifdef.c               |  22 +++++++++++-----------
 usr.bin/usbhidctl/usbhid.c              |  10 +++++-----
 usr.bin/uuencode/uuencode.c             |   7 +++----
 usr.bin/uuidgen/uuidgen.c               |   6 +++---
 usr.bin/videoctl/videoctl.c             |   6 +++---
 usr.bin/w/w.c                           |   8 +++-----
 usr.bin/wc/wc.c                         |   7 +++----
 usr.bin/xstr/xstr.c                     |  10 ++++------
 usr.sbin/faithd/faithd.c                |   4 ++--
 usr.sbin/faithd/faithd.h                |   4 ++--
 57 files changed, 183 insertions(+), 207 deletions(-)

diffs (truncated from 1641 to 300 lines):

diff -r 4691f8589a3f -r cdf947287137 distrib/utils/sysinst/aout2elf.c
--- a/distrib/utils/sysinst/aout2elf.c  Fri Sep 16 15:38:03 2011 +0000
+++ b/distrib/utils/sysinst/aout2elf.c  Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: aout2elf.c,v 1.16 2011/04/04 08:30:12 mbalmer Exp $
+/*     $NetBSD: aout2elf.c,v 1.17 2011/09/16 15:42:28 joerg Exp $
  *
  * Copyright 1997 Piermont Information Systems Inc.
  * All rights reserved.
@@ -192,7 +192,7 @@
        return n;
 }
 
-static void
+__dead static void
 abort_libupdate(void)
 {
        msg_display(MSG_aoutfail);
diff -r 4691f8589a3f -r cdf947287137 distrib/utils/sysinst/main.c
--- a/distrib/utils/sysinst/main.c      Fri Sep 16 15:38:03 2011 +0000
+++ b/distrib/utils/sysinst/main.c      Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: main.c,v 1.60 2011/05/30 14:20:48 joerg Exp $  */
+/*     $NetBSD: main.c,v 1.61 2011/09/16 15:42:28 joerg Exp $  */
 
 /*
  * Copyright 1997 Piermont Information Systems Inc.
@@ -53,8 +53,8 @@
 
 int main(int, char **);
 static void select_language(void);
-static void usage(void);
-static void miscsighandler(int);
+__dead static void usage(void);
+__dead static void miscsighandler(int);
 static void ttysighandler(int);
 static void cleanup(void);
 static void process_f_flag(char *);
diff -r 4691f8589a3f -r cdf947287137 usr.bin/dirname/dirname.c
--- a/usr.bin/dirname/dirname.c Fri Sep 16 15:38:03 2011 +0000
+++ b/usr.bin/dirname/dirname.c Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: dirname.c,v 1.11 2008/07/21 14:19:22 lukem Exp $       */
+/*     $NetBSD: dirname.c,v 1.12 2011/09/16 15:39:25 joerg Exp $       */
 
 /*-
  * Copyright (c) 1991, 1993, 1994
@@ -39,7 +39,7 @@
 #if 0
 static char sccsid[] = "@(#)dirname.c  8.4 (Berkeley) 5/4/95";
 #endif
-__RCSID("$NetBSD: dirname.c,v 1.11 2008/07/21 14:19:22 lukem Exp $");
+__RCSID("$NetBSD: dirname.c,v 1.12 2011/09/16 15:39:25 joerg Exp $");
 #endif /* not lint */
 
 #include <err.h>
@@ -49,7 +49,7 @@
 #include <stdlib.h>
 #include <unistd.h>
 
-static void usage(void);
+__dead static void usage(void);
 
 int
 main(int argc, char **argv)
diff -r 4691f8589a3f -r cdf947287137 usr.bin/extattr/getextattr.c
--- a/usr.bin/extattr/getextattr.c      Fri Sep 16 15:38:03 2011 +0000
+++ b/usr.bin/extattr/getextattr.c      Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: getextattr.c,v 1.8 2011/07/14 15:25:27 manu Exp $      */
+/*     $NetBSD: getextattr.c,v 1.9 2011/09/16 15:39:25 joerg Exp $     */
 
 /*-
  * Copyright (c) 2002, 2003 Networks Associates Technology, Inc.
@@ -56,7 +56,7 @@
 
 static enum { EADUNNO, EAGET, EASET, EARM, EALS } what = EADUNNO;
 
-static void
+__dead static void
 usage(void) 
 {
 
diff -r 4691f8589a3f -r cdf947287137 usr.bin/find/main.c
--- a/usr.bin/find/main.c       Fri Sep 16 15:38:03 2011 +0000
+++ b/usr.bin/find/main.c       Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: main.c,v 1.29 2010/12/28 15:28:31 christos Exp $       */
+/*     $NetBSD: main.c,v 1.30 2011/09/16 15:39:25 joerg Exp $  */
 
 /*-
  * Copyright (c) 1990, 1993, 1994
@@ -39,7 +39,7 @@
 #else
 __COPYRIGHT("@(#) Copyright (c) 1990, 1993, 1994\
  The Regents of the University of California.  All rights reserved.");
-__RCSID("$NetBSD: main.c,v 1.29 2010/12/28 15:28:31 christos Exp $");
+__RCSID("$NetBSD: main.c,v 1.30 2011/09/16 15:39:25 joerg Exp $");
 #endif
 #endif /* not lint */
 
@@ -69,8 +69,7 @@
 int isxargs;                   /* don't permit xargs delimiting chars */
 int regcomp_flags = REG_BASIC; /* regex compilation flags */
 
-int main(int, char **);
-static void usage(void);
+__dead static void usage(void);
 
 int
 main(int argc, char *argv[])
diff -r 4691f8589a3f -r cdf947287137 usr.bin/fsplit/fsplit.c
--- a/usr.bin/fsplit/fsplit.c   Fri Sep 16 15:38:03 2011 +0000
+++ b/usr.bin/fsplit/fsplit.c   Fri Sep 16 15:39:25 2011 +0000
@@ -40,7 +40,7 @@
 #if 0
 static char sccsid[] = "from: @(#)fsplit.c     8.1 (Berkeley) 6/6/93";
 #else
-__RCSID("$NetBSD: fsplit.c,v 1.27 2009/07/13 19:05:40 roy Exp $");
+__RCSID("$NetBSD: fsplit.c,v 1.28 2011/09/16 15:39:26 joerg Exp $");
 #endif
 #endif /* not lint */
 
@@ -89,7 +89,7 @@
 static char mainp[] = "main000.f";
 static char blkp[] = "blkdta000.f";
 
-static void badparms(void);
+__dead static void badparms(void);
 static const char *functs(const char *);
 static int get_line(void);
 static void get_name(char *, int);
diff -r 4691f8589a3f -r cdf947287137 usr.bin/ftp/cmds.c
--- a/usr.bin/ftp/cmds.c        Fri Sep 16 15:38:03 2011 +0000
+++ b/usr.bin/ftp/cmds.c        Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: cmds.c,v 1.131 2010/01/12 06:50:04 lukem Exp $ */
+/*     $NetBSD: cmds.c,v 1.132 2011/09/16 15:39:26 joerg Exp $ */
 
 /*-
  * Copyright (c) 1996-2009 The NetBSD Foundation, Inc.
@@ -96,7 +96,7 @@
 #if 0
 static char sccsid[] = "@(#)cmds.c     8.6 (Berkeley) 10/9/94";
 #else
-__RCSID("$NetBSD: cmds.c,v 1.131 2010/01/12 06:50:04 lukem Exp $");
+__RCSID("$NetBSD: cmds.c,v 1.132 2011/09/16 15:39:26 joerg Exp $");
 #endif
 #endif /* not lint */
 
@@ -142,7 +142,7 @@
 static sigjmp_buf       jabort;
 
 static int     confirm(const char *, const char *);
-static void    mintr(int);
+__dead static void     mintr(int);
 static void    mabort(const char *);
 static void    set_type(const char *);
 
diff -r 4691f8589a3f -r cdf947287137 usr.bin/ftp/extern.h
--- a/usr.bin/ftp/extern.h      Fri Sep 16 15:38:03 2011 +0000
+++ b/usr.bin/ftp/extern.h      Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: extern.h,v 1.78 2010/03/04 21:40:53 lukem Exp $        */
+/*     $NetBSD: extern.h,v 1.79 2011/09/16 15:39:26 joerg Exp $        */
 
 /*-
  * Copyright (c) 1996-2009 The NetBSD Foundation, Inc.
@@ -94,9 +94,6 @@
 struct addrinfo;
 
 void   abort_remote(FILE *);
-void   abort_squared(int);
-void   abortpt(int);
-void   abortxfer(int);
 void   account(int, char **);
 void   ai_unmapped(struct addrinfo *);
 int    another(int *, char ***, const char *);
@@ -145,7 +142,7 @@
 char   *hookup(const char *, const char *);
 void   idlecmd(int, char **);
 int    initconn(void);
-void   intr(int);
+__dead void    intr(int);
 int    isipv6addr(const char *);
 void   list_vertical(StringList *);
 void   lcd(int, char **);
@@ -169,7 +166,7 @@
 const char *parse_rfc2616time(struct tm *, const char *);
 int    parserate(int, char **, int);
 char   *prompt(void);
-void   proxabort(int);
+__dead void    proxabort(int);
 void   proxtrans(const char *, const char *, const char *);
 void   psabort(int);
 void   pswitch(int);
@@ -241,7 +238,6 @@
 void   unsetoption(int, char **);
 void   updatelocalcwd(void);
 void   updateremotecwd(void);
-void   usage(void);
 void   user(int, char **);
 int    ftp_connect(int, const struct sockaddr *, socklen_t);
 int    ftp_listen(int, int);
diff -r 4691f8589a3f -r cdf947287137 usr.bin/ftp/fetch.c
--- a/usr.bin/ftp/fetch.c       Fri Sep 16 15:38:03 2011 +0000
+++ b/usr.bin/ftp/fetch.c       Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: fetch.c,v 1.193 2010/03/05 07:41:10 lukem Exp $        */
+/*     $NetBSD: fetch.c,v 1.194 2011/09/16 15:39:26 joerg Exp $        */
 
 /*-
  * Copyright (c) 1997-2009 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: fetch.c,v 1.193 2010/03/05 07:41:10 lukem Exp $");
+__RCSID("$NetBSD: fetch.c,v 1.194 2011/09/16 15:39:26 joerg Exp $");
 #endif /* not lint */
 
 /*
@@ -74,7 +74,7 @@
        CLASSIC_URL_T
 } url_t;
 
-void           aborthttp(int);
+__dead static void     aborthttp(int);
 #ifndef NO_AUTH
 static int     auth_url(const char *, char **, const char *, const char *);
 static void    base64_encode(const unsigned char *, size_t, unsigned char *);
@@ -1323,7 +1323,7 @@
 /*
  * Abort a HTTP retrieval
  */
-void
+static void
 aborthttp(int notused)
 {
        char msgbuf[100];
diff -r 4691f8589a3f -r cdf947287137 usr.bin/ftp/ftp.c
--- a/usr.bin/ftp/ftp.c Fri Sep 16 15:38:03 2011 +0000
+++ b/usr.bin/ftp/ftp.c Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ftp.c,v 1.161 2011/08/14 12:58:15 christos Exp $       */
+/*     $NetBSD: ftp.c,v 1.162 2011/09/16 15:39:26 joerg Exp $  */
 
 /*-
  * Copyright (c) 1996-2009 The NetBSD Foundation, Inc.
@@ -92,7 +92,7 @@
 #if 0
 static char sccsid[] = "@(#)ftp.c      8.6 (Berkeley) 10/27/94";
 #else
-__RCSID("$NetBSD: ftp.c,v 1.161 2011/08/14 12:58:15 christos Exp $");
+__RCSID("$NetBSD: ftp.c,v 1.162 2011/09/16 15:39:26 joerg Exp $");
 #endif
 #endif /* not lint */
 
@@ -131,6 +131,7 @@
 char   pasv[BUFSIZ];   /* passive port for proxy data connection */
 
 static int empty(FILE *, FILE *, int);
+__dead static void abort_squared(int);
 
 struct sockinet {
        union sockunion {
@@ -537,7 +538,7 @@
 
 sigjmp_buf     xferabort;
 
-void
+__dead static void
 abortxfer(int notused)
 {
        char msgbuf[100];
@@ -1819,7 +1820,7 @@
        }
 }
 
-void
+__dead static void
 abortpt(int notused)
 {
 
@@ -2031,7 +2032,7 @@
  *     too impatient to wait or there's another problem then ftp really
  *     needs to get back to a known state.
  */
-void
+static void
 abort_squared(int dummy)
 {
        char msgbuf[100];
diff -r 4691f8589a3f -r cdf947287137 usr.bin/ftp/main.c
--- a/usr.bin/ftp/main.c        Fri Sep 16 15:38:03 2011 +0000
+++ b/usr.bin/ftp/main.c        Fri Sep 16 15:39:25 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: main.c,v 1.118 2011/08/14 12:58:15 christos Exp $      */
+/*     $NetBSD: main.c,v 1.119 2011/09/16 15:39:26 joerg Exp $ */
 



Home | Main Index | Thread Index | Old Index