From 85cbf55d16cddafeebefce77710e3a2926d08556 Mon Sep 17 00:00:00 2001 From: drochner Date: Tue, 9 Nov 1999 15:06:30 +0000 Subject: [PATCH] Since our gcc doesn't warn about NULL format strings anymore, we can fix the incorrect err(1, "%s", "") et al. Closes PR bin/7592 by cgd. --- bin/dd/dd.c | 8 ++++---- bin/expr/expr.c | 8 ++++---- bin/ls/ls.c | 8 ++++---- bin/ls/print.c | 6 +++--- bin/mv/mv.c | 6 +++--- bin/ps/keyword.c | 6 +++--- bin/ps/ps.c | 8 ++++---- bin/pwd/pwd.c | 6 +++--- bin/rcp/rcp.c | 14 +++++++------- bin/rm/rm.c | 6 +++--- games/cribbage/instr.c | 6 +++--- games/fortune/fortune/fortune.c | 10 +++++----- libexec/getNAME/getNAME.c | 8 ++++---- sbin/init/init.c | 6 +++--- sbin/mount/getmntopts.c | 6 +++--- sbin/restore/main.c | 8 ++++---- sbin/route/show.c | 6 +++--- sbin/umount/umount.c | 6 +++--- usr.bin/calendar/calendar.c | 6 +++--- usr.bin/find/function.c | 6 +++--- usr.bin/finger/finger.c | 8 ++------ usr.bin/finger/util.c | 16 ++-------------- usr.bin/head/head.c | 6 +++--- usr.bin/hexdump/display.c | 6 +++--- usr.bin/id/id.c | 4 ++-- usr.bin/sed/process.c | 6 +++--- usr.bin/soelim/soelim.c | 8 ++++---- usr.bin/su/su.c | 6 +++--- usr.bin/tset/term.c | 6 +++--- usr.bin/w/w.c | 6 +++--- usr.bin/whereis/whereis.c | 6 +++--- usr.bin/write/write.c | 6 +++--- usr.bin/xstr/xstr.c | 8 ++++---- usr.sbin/chown/chown.c | 6 +++--- usr.sbin/netgroup_mkdb/util.c | 10 ++++------ 35 files changed, 117 insertions(+), 135 deletions(-) diff --git a/bin/dd/dd.c b/bin/dd/dd.c index 8ed09d394268..14ef0774c6c6 100644 --- a/bin/dd/dd.c +++ b/bin/dd/dd.c @@ -1,4 +1,4 @@ -/* $NetBSD: dd.c,v 1.13 1999/07/29 19:03:31 hubertf Exp $ */ +/* $NetBSD: dd.c,v 1.14 1999/11/09 15:06:31 drochner Exp $ */ /*- * Copyright (c) 1991, 1993, 1994 @@ -47,7 +47,7 @@ __COPYRIGHT("@(#) Copyright (c) 1991, 1993, 1994\n\ #if 0 static char sccsid[] = "@(#)dd.c 8.5 (Berkeley) 4/2/94"; #else -__RCSID("$NetBSD: dd.c,v 1.13 1999/07/29 19:03:31 hubertf Exp $"); +__RCSID("$NetBSD: dd.c,v 1.14 1999/11/09 15:06:31 drochner Exp $"); #endif #endif /* not lint */ @@ -156,12 +156,12 @@ setup() */ if (!(ddflags & (C_BLOCK|C_UNBLOCK))) { if ((in.db = malloc(out.dbsz + in.dbsz - 1)) == NULL) - err(1, "%s", ""); + err(1, NULL); out.db = in.db; } else if ((in.db = malloc((u_int)(MAX(in.dbsz, cbsz) + cbsz))) == NULL || (out.db = malloc((u_int)(out.dbsz + cbsz))) == NULL) - err(1, "%s", ""); + err(1, NULL); in.dbp = in.db; out.dbp = out.db; diff --git a/bin/expr/expr.c b/bin/expr/expr.c index 196c0e4d1c39..730b5c841682 100644 --- a/bin/expr/expr.c +++ b/bin/expr/expr.c @@ -1,4 +1,4 @@ -/* $NetBSD: expr.c,v 1.10 1998/11/04 14:11:12 christos Exp $ */ +/* $NetBSD: expr.c,v 1.11 1999/11/09 15:06:31 drochner Exp $ */ /* * Written by J.T. Conklin . @@ -62,7 +62,7 @@ make_int(i) vp = (struct val *) malloc(sizeof(*vp)); if (vp == NULL) { - err(2, "%s", ""); + err(2, NULL); } vp->type = integer; vp->u.i = i; @@ -78,7 +78,7 @@ make_str(s) vp = (struct val *) malloc(sizeof(*vp)); if (vp == NULL || ((vp->u.s = strdup(s)) == NULL)) { - err(2, "%s", ""); + err(2, NULL); } vp->type = string; return vp; @@ -172,7 +172,7 @@ to_string(vp) tmp = malloc(25); if (tmp == NULL) { - err(2, "%s", ""); + err(2, NULL); } (void)snprintf(tmp, 25, "%d", vp->u.i); vp->type = string; diff --git a/bin/ls/ls.c b/bin/ls/ls.c index 1fe300e24939..955c06c46219 100644 --- a/bin/ls/ls.c +++ b/bin/ls/ls.c @@ -1,4 +1,4 @@ -/* $NetBSD: ls.c,v 1.39 1999/11/02 19:44:07 tron Exp $ */ +/* $NetBSD: ls.c,v 1.40 1999/11/09 15:06:31 drochner Exp $ */ /* * Copyright (c) 1989, 1993, 1994 @@ -46,7 +46,7 @@ __COPYRIGHT("@(#) Copyright (c) 1989, 1993, 1994\n\ #if 0 static char sccsid[] = "@(#)ls.c 8.7 (Berkeley) 8/5/94"; #else -__RCSID("$NetBSD: ls.c,v 1.39 1999/11/02 19:44:07 tron Exp $"); +__RCSID("$NetBSD: ls.c,v 1.40 1999/11/09 15:06:31 drochner Exp $"); #endif #endif /* not lint */ @@ -352,7 +352,7 @@ traverse(argc, argv, options) if ((ftsp = fts_open(argv, options, f_nosort ? NULL : mastercmp)) == NULL) - err(EXIT_FAILURE, "%s", ""); + err(EXIT_FAILURE, NULL); display(NULL, fts_children(ftsp, 0)); if (f_listdir) @@ -527,7 +527,7 @@ display(p, list) if ((np = malloc(sizeof(NAMES) + ulen + glen + flen + 3)) == NULL) - err(EXIT_FAILURE, "%s", ""); + err(EXIT_FAILURE, NULL); np->user = &np->data[0]; (void)strcpy(np->user, user); diff --git a/bin/ls/print.c b/bin/ls/print.c index a09ddcb915fb..b0ea7d6e400c 100644 --- a/bin/ls/print.c +++ b/bin/ls/print.c @@ -1,4 +1,4 @@ -/* $NetBSD: print.c,v 1.26 1999/02/17 15:28:09 kleink Exp $ */ +/* $NetBSD: print.c,v 1.27 1999/11/09 15:06:31 drochner Exp $ */ /* * Copyright (c) 1989, 1993, 1994 @@ -41,7 +41,7 @@ #if 0 static char sccsid[] = "@(#)print.c 8.5 (Berkeley) 7/28/94"; #else -__RCSID("$NetBSD: print.c,v 1.26 1999/02/17 15:28:09 kleink Exp $"); +__RCSID("$NetBSD: print.c,v 1.27 1999/11/09 15:06:31 drochner Exp $"); #endif #endif /* not lint */ @@ -175,7 +175,7 @@ printcol(dp) lastentries = dp->entries; if ((array = realloc(array, dp->entries * sizeof(FTSENT *))) == NULL) { - warn("%s", ""); + warn(NULL); printscol(dp); } } diff --git a/bin/mv/mv.c b/bin/mv/mv.c index c155587ce835..29feb90760a7 100644 --- a/bin/mv/mv.c +++ b/bin/mv/mv.c @@ -1,4 +1,4 @@ -/* $NetBSD: mv.c,v 1.22 1999/08/16 07:49:45 christos Exp $ */ +/* $NetBSD: mv.c,v 1.23 1999/11/09 15:06:31 drochner Exp $ */ /* * Copyright (c) 1989, 1993, 1994 @@ -46,7 +46,7 @@ __COPYRIGHT("@(#) Copyright (c) 1989, 1993, 1994\n\ #if 0 static char sccsid[] = "@(#)mv.c 8.2 (Berkeley) 4/2/94"; #else -__RCSID("$NetBSD: mv.c,v 1.22 1999/08/16 07:49:45 christos Exp $"); +__RCSID("$NetBSD: mv.c,v 1.23 1999/11/09 15:06:31 drochner Exp $"); #endif #endif /* not lint */ @@ -267,7 +267,7 @@ fastcopy(from, to, sbp) return (1); } if (!blen && !(bp = malloc(blen = sbp->st_blksize))) { - warn("%s", ""); + warn(NULL); return (1); } while ((nread = read(from_fd, bp, blen)) > 0) diff --git a/bin/ps/keyword.c b/bin/ps/keyword.c index 528a80e89d72..e8e73ee69566 100644 --- a/bin/ps/keyword.c +++ b/bin/ps/keyword.c @@ -1,4 +1,4 @@ -/* $NetBSD: keyword.c,v 1.19 1999/05/03 00:17:30 mrg Exp $ */ +/* $NetBSD: keyword.c,v 1.20 1999/11/09 15:06:31 drochner Exp $ */ /*- * Copyright (c) 1990, 1993, 1994 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "@(#)keyword.c 8.5 (Berkeley) 4/2/94"; #else -__RCSID("$NetBSD: keyword.c,v 1.19 1999/05/03 00:17:30 mrg Exp $"); +__RCSID("$NetBSD: keyword.c,v 1.20 1999/11/09 15:06:31 drochner Exp $"); #endif #endif /* not lint */ @@ -226,7 +226,7 @@ parsefmt(p) if (!(v = findvar(cp))) continue; if ((vent = malloc(sizeof(struct varent))) == NULL) - err(1, "%s", ""); + err(1, NULL); vent->var = v; vent->next = NULL; if (vhead == NULL) diff --git a/bin/ps/ps.c b/bin/ps/ps.c index cd1bfa919abf..8c37e07ec9b9 100644 --- a/bin/ps/ps.c +++ b/bin/ps/ps.c @@ -1,4 +1,4 @@ -/* $NetBSD: ps.c,v 1.31 1999/10/15 20:39:52 jdolecek Exp $ */ +/* $NetBSD: ps.c,v 1.32 1999/11/09 15:06:31 drochner Exp $ */ /*- * Copyright (c) 1990, 1993, 1994 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1990, 1993, 1994\n\ #if 0 static char sccsid[] = "@(#)ps.c 8.4 (Berkeley) 4/2/94"; #else -__RCSID("$NetBSD: ps.c,v 1.31 1999/10/15 20:39:52 jdolecek Exp $"); +__RCSID("$NetBSD: ps.c,v 1.32 1999/11/09 15:06:31 drochner Exp $"); #endif #endif /* not lint */ @@ -411,7 +411,7 @@ getkinfo_kvm(kd, what, flag, nentriesp, needuser) if ((kp = kvm_getprocs(kd, what, flag, nentriesp)) != 0) { if ((kinfo = malloc((*nentriesp) * sizeof(*kinfo))) == NULL) - err(1, "%s", ""); + err(1, NULL); for (i = (*nentriesp); i-- > 0; kp++) { kinfo[i].ki_p = kp; if (needuser) @@ -509,7 +509,7 @@ kludge_oldps_options(s) len = strlen(s); if ((newopts = ns = malloc(len + 3)) == NULL) - err(1, "%s", ""); + err(1, NULL); /* * options begin with '-' */ diff --git a/bin/pwd/pwd.c b/bin/pwd/pwd.c index 43d8c787760a..1b090e82167a 100644 --- a/bin/pwd/pwd.c +++ b/bin/pwd/pwd.c @@ -1,4 +1,4 @@ -/* $NetBSD: pwd.c,v 1.12 1999/05/31 14:31:07 kleink Exp $ */ +/* $NetBSD: pwd.c,v 1.13 1999/11/09 15:06:32 drochner Exp $ */ /* * Copyright (c) 1991, 1993, 1994 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1991, 1993, 1994\n\ #if 0 static char sccsid[] = "@(#)pwd.c 8.3 (Berkeley) 4/1/94"; #else -__RCSID("$NetBSD: pwd.c,v 1.12 1999/05/31 14:31:07 kleink Exp $"); +__RCSID("$NetBSD: pwd.c,v 1.13 1999/11/09 15:06:32 drochner Exp $"); #endif #endif /* not lint */ @@ -93,7 +93,7 @@ main(argc, argv) p = getcwd(NULL, 0); if (p == NULL) - err(EXIT_FAILURE, "%s", ""); + err(EXIT_FAILURE, NULL); (void)printf("%s\n", p); diff --git a/bin/rcp/rcp.c b/bin/rcp/rcp.c index 657cfd961c48..8e0bae88ef84 100644 --- a/bin/rcp/rcp.c +++ b/bin/rcp/rcp.c @@ -1,4 +1,4 @@ -/* $NetBSD: rcp.c,v 1.25 1999/02/17 06:45:38 scottr Exp $ */ +/* $NetBSD: rcp.c,v 1.26 1999/11/09 15:06:32 drochner Exp $ */ /* * Copyright (c) 1983, 1990, 1992, 1993 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1983, 1990, 1992, 1993\n\ #if 0 static char sccsid[] = "@(#)rcp.c 8.2 (Berkeley) 4/2/94"; #else -__RCSID("$NetBSD: rcp.c,v 1.25 1999/02/17 06:45:38 scottr Exp $"); +__RCSID("$NetBSD: rcp.c,v 1.26 1999/11/09 15:06:32 drochner Exp $"); #endif #endif /* not lint */ @@ -194,7 +194,7 @@ main(argc, argv) errx(1, "unknown user %d", (int)userid); if ((pwname = strdup(pwd->pw_name)) == NULL) - err(1, "%s", ""); + err(1, NULL); rem = STDIN_FILENO; /* XXX */ @@ -280,7 +280,7 @@ toremote(targ, argc, argv) strlen(src) + (tuser ? strlen(tuser) : 0) + strlen(thost) + strlen(targ) + CMDNEEDS + 20; if (!(bp = malloc(len))) - err(1, "%s", ""); + err(1, NULL); if (host) { *host++ = 0; suser = argv[i]; @@ -305,7 +305,7 @@ toremote(targ, argc, argv) if (rem == -1) { len = strlen(targ) + CMDNEEDS + 20; if (!(bp = malloc(len))) - err(1, "%s", ""); + err(1, NULL); (void)snprintf(bp, len, "%s -t %s", cmd, targ); host = thost; #ifdef KERBEROS @@ -341,7 +341,7 @@ tolocal(argc, argv) len = strlen(_PATH_CP) + strlen(argv[i]) + strlen(argv[argc - 1]) + 20; if (!(bp = malloc(len))) - err(1, "%s", ""); + err(1, NULL); (void)snprintf(bp, len, "exec %s%s%s %s %s", _PATH_CP, iamrecursive ? " -r" : "", pflag ? " -p" : "", argv[i], argv[argc - 1]); @@ -366,7 +366,7 @@ tolocal(argc, argv) } len = strlen(src) + CMDNEEDS + 20; if ((bp = malloc(len)) == NULL) - err(1, "%s", ""); + err(1, NULL); (void)snprintf(bp, len, "%s -f %s", cmd, src); rem = #ifdef KERBEROS diff --git a/bin/rm/rm.c b/bin/rm/rm.c index 9301258c2f4d..5f95db1505d6 100644 --- a/bin/rm/rm.c +++ b/bin/rm/rm.c @@ -1,4 +1,4 @@ -/* $NetBSD: rm.c,v 1.25 1999/06/30 10:18:59 is Exp $ */ +/* $NetBSD: rm.c,v 1.26 1999/11/09 15:06:32 drochner Exp $ */ /*- * Copyright (c) 1990, 1993, 1994 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1990, 1993, 1994\n\ #if 0 static char sccsid[] = "@(#)rm.c 8.8 (Berkeley) 4/27/95"; #else -__RCSID("$NetBSD: rm.c,v 1.25 1999/06/30 10:18:59 is Exp $"); +__RCSID("$NetBSD: rm.c,v 1.26 1999/11/09 15:06:32 drochner Exp $"); #endif #endif /* not lint */ @@ -173,7 +173,7 @@ rm_tree(argv) flags |= FTS_WHITEOUT; if (!(fts = fts_open(argv, flags, (int (*) __P((const FTSENT **, const FTSENT **)))NULL))) - err(1, "%s", ""); + err(1, NULL); while ((p = fts_read(fts)) != NULL) { switch (p->fts_info) { case FTS_DNR: diff --git a/games/cribbage/instr.c b/games/cribbage/instr.c index 5de9b9e10077..5c7738c00b09 100644 --- a/games/cribbage/instr.c +++ b/games/cribbage/instr.c @@ -1,4 +1,4 @@ -/* $NetBSD: instr.c,v 1.8 1999/09/13 17:27:36 jsm Exp $ */ +/* $NetBSD: instr.c,v 1.9 1999/11/09 15:06:32 drochner Exp $ */ /*- * Copyright (c) 1990, 1993 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "@(#)instr.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: instr.c,v 1.8 1999/09/13 17:27:36 jsm Exp $"); +__RCSID("$NetBSD: instr.c,v 1.9 1999/11/09 15:06:32 drochner Exp $"); #endif #endif /* not lint */ @@ -90,7 +90,7 @@ instructions() _exit(1); } execl("/bin/sh", "sh", "-c", path, NULL); - warn("%s", ""); + warn(NULL); _exit(1); default: do { diff --git a/games/fortune/fortune/fortune.c b/games/fortune/fortune/fortune.c index 86a17b7a8a84..559039c73a5c 100644 --- a/games/fortune/fortune/fortune.c +++ b/games/fortune/fortune/fortune.c @@ -1,4 +1,4 @@ -/* $NetBSD: fortune.c,v 1.21 1999/09/22 18:56:32 jsm Exp $ */ +/* $NetBSD: fortune.c,v 1.22 1999/11/09 15:06:33 drochner Exp $ */ /*- * Copyright (c) 1986, 1993 @@ -46,7 +46,7 @@ __COPYRIGHT("@(#) Copyright (c) 1986, 1993\n\ #if 0 static char sccsid[] = "@(#)fortune.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: fortune.c,v 1.21 1999/09/22 18:56:32 jsm Exp $"); +__RCSID("$NetBSD: fortune.c,v 1.22 1999/11/09 15:06:33 drochner Exp $"); #endif #endif /* not lint */ @@ -191,7 +191,7 @@ char *regcmp(), *regex(); regex_t *Re_pat = NULL; # define RE_INIT() if (Re_pat == NULL && \ (Re_pat = calloc(sizeof(*Re_pat), 1)) == NULL)\ - err(1, "%s", "") + err(1, NULL) # define RE_COMP(p) (regcomp(Re_pat, p, REG_EXTENDED)) # define BAD_COMP(f) ((f) != 0) # define RE_EXEC(p) (!regexec(Re_pat, p, 0, NULL, 0)) @@ -859,7 +859,7 @@ do_malloc(size) void *new; if ((new = malloc(size)) == NULL) - err(1, "%s", ""); + err(1, NULL); return new; } @@ -1243,7 +1243,7 @@ conv_pat(orig) else cnt++; if ((new = malloc(cnt)) == NULL) - err(1, "%s", ""); + err(1, NULL); for (sp = new; *orig != '\0'; orig++) { if (islower(*orig)) { diff --git a/libexec/getNAME/getNAME.c b/libexec/getNAME/getNAME.c index 1a49a51821d5..18ade1c044c7 100644 --- a/libexec/getNAME/getNAME.c +++ b/libexec/getNAME/getNAME.c @@ -1,4 +1,4 @@ -/* $NetBSD: getNAME.c,v 1.16 1999/02/08 20:05:57 augustss Exp $ */ +/* $NetBSD: getNAME.c,v 1.17 1999/11/09 15:06:33 drochner Exp $ */ /*- * Copyright (c) 1997, Christos Zoulas @@ -42,7 +42,7 @@ __COPYRIGHT("@(#) Copyright (c) 1980, 1993\n\ #if 0 static char sccsid[] = "@(#)getNAME.c 8.1 (Berkeley) 6/30/93"; #else -__RCSID("$NetBSD: getNAME.c,v 1.16 1999/02/08 20:05:57 augustss Exp $"); +__RCSID("$NetBSD: getNAME.c,v 1.17 1999/11/09 15:06:33 drochner Exp $"); #endif #endif /* not lint */ @@ -229,7 +229,7 @@ oldman(pathname, name) if (maxlen + extlen < curlen + len + SLOP) { maxlen = 2 * (curlen + len) + SLOP + extlen; if ((linebuf = realloc(linebuf, maxlen)) == NULL) - err(1, "%s", ""); + err(1, NULL); } if (i != 0) linebuf[curlen++] = ' '; @@ -330,7 +330,7 @@ newman(pathname, name) if (maxlen + extlen < curlen + len + SLOP) { maxlen = 2 * (curlen + len) + SLOP + extlen; if ((linebuf = realloc(linebuf, maxlen)) == NULL) - err(1, "%s", ""); + err(1, NULL); } if (i != 0) diff --git a/sbin/init/init.c b/sbin/init/init.c index f907aa94100f..8dbd096d55a4 100644 --- a/sbin/init/init.c +++ b/sbin/init/init.c @@ -1,4 +1,4 @@ -/* $NetBSD: init.c,v 1.34 1998/11/14 07:17:58 tls Exp $ */ +/* $NetBSD: init.c,v 1.35 1999/11/09 15:06:33 drochner Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -46,7 +46,7 @@ __COPYRIGHT("@(#) Copyright (c) 1991, 1993\n" #if 0 static char sccsid[] = "@(#)init.c 8.2 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: init.c,v 1.34 1998/11/14 07:17:58 tls Exp $"); +__RCSID("$NetBSD: init.c,v 1.35 1999/11/09 15:06:33 drochner Exp $"); #endif #endif /* not lint */ @@ -197,7 +197,7 @@ main(argc, argv) /* Dispose of random users. */ if (getuid() != 0) { errno = EPERM; - err(1, "%s", ""); + err(1, NULL); } /* System V users like to reexec init. */ diff --git a/sbin/mount/getmntopts.c b/sbin/mount/getmntopts.c index f9e061ad0dee..6615f03ce1cd 100644 --- a/sbin/mount/getmntopts.c +++ b/sbin/mount/getmntopts.c @@ -1,4 +1,4 @@ -/* $NetBSD: getmntopts.c,v 1.5 1997/09/16 12:22:42 lukem Exp $ */ +/* $NetBSD: getmntopts.c,v 1.6 1999/11/09 15:06:33 drochner Exp $ */ /*- * Copyright (c) 1994 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "@(#)getmntopts.c 8.3 (Berkeley) 3/29/95"; #else -__RCSID("$NetBSD: getmntopts.c,v 1.5 1997/09/16 12:22:42 lukem Exp $"); +__RCSID("$NetBSD: getmntopts.c,v 1.6 1999/11/09 15:06:33 drochner Exp $"); #endif #endif /* not lint */ @@ -69,7 +69,7 @@ getmntopts(options, m0, flagp, altflagp) /* Copy option string, since it is about to be torn asunder... */ if ((optbuf = strdup(options)) == NULL) - err(1, "%s", ""); + err(1, NULL); for (opt = optbuf; (opt = strtok(opt, ",")) != NULL; opt = NULL) { /* Check for "no" prefix. */ diff --git a/sbin/restore/main.c b/sbin/restore/main.c index 2ef4924160de..b8d4613872e9 100644 --- a/sbin/restore/main.c +++ b/sbin/restore/main.c @@ -1,4 +1,4 @@ -/* $NetBSD: main.c,v 1.18 1998/06/24 19:56:11 christos Exp $ */ +/* $NetBSD: main.c,v 1.19 1999/11/09 15:06:33 drochner Exp $ */ /* * Copyright (c) 1983, 1993 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1983, 1993\n\ #if 0 static char sccsid[] = "@(#)main.c 8.6 (Berkeley) 5/4/95"; #else -__RCSID("$NetBSD: main.c,v 1.18 1998/06/24 19:56:11 christos Exp $"); +__RCSID("$NetBSD: main.c,v 1.19 1999/11/09 15:06:33 drochner Exp $"); #endif #endif /* not lint */ @@ -335,7 +335,7 @@ obsolete(argcp, argvp) /* Allocate space for new arguments. */ if ((*argvp = nargv = malloc((argc + 1) * sizeof(char *))) == NULL || (p = flagsp = malloc(strlen(ap) + 2)) == NULL) - err(1, "%s", ""); + err(1, NULL); *nargv++ = *argv; argv += 2; @@ -350,7 +350,7 @@ obsolete(argcp, argvp) usage(); } if ((nargv[0] = malloc(strlen(*argv) + 2 + 1)) == NULL) - err(1, "%s", ""); + err(1, NULL); nargv[0][0] = '-'; nargv[0][1] = *ap; (void)strcpy(&nargv[0][2], *argv); diff --git a/sbin/route/show.c b/sbin/route/show.c index 963c086e0e8a..dea5cb267a68 100644 --- a/sbin/route/show.c +++ b/sbin/route/show.c @@ -1,4 +1,4 @@ -/* $NetBSD: show.c,v 1.13 1999/09/03 04:17:19 itojun Exp $ */ +/* $NetBSD: show.c,v 1.14 1999/11/09 15:06:34 drochner Exp $ */ /* * Copyright (c) 1983, 1988, 1993 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "from: @(#)route.c 8.3 (Berkeley) 3/9/94"; #else -__RCSID("$NetBSD: show.c,v 1.13 1999/09/03 04:17:19 itojun Exp $"); +__RCSID("$NetBSD: show.c,v 1.14 1999/11/09 15:06:34 drochner Exp $"); #endif #endif /* not lint */ @@ -124,7 +124,7 @@ show(argc, argv) exit(1); } if ((buf = malloc(needed)) == 0) - err(1, "%s", ""); + err(1, NULL); if (sysctl(mib, 6, buf, &needed, NULL, 0) < 0) err(1, "sysctl of routing table"); lim = buf + needed; diff --git a/sbin/umount/umount.c b/sbin/umount/umount.c index 273b60196475..f471f649419b 100644 --- a/sbin/umount/umount.c +++ b/sbin/umount/umount.c @@ -1,4 +1,4 @@ -/* $NetBSD: umount.c,v 1.25 1999/08/02 02:40:38 sommerfeld Exp $ */ +/* $NetBSD: umount.c,v 1.26 1999/11/09 15:06:34 drochner Exp $ */ /*- * Copyright (c) 1980, 1989, 1993 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1980, 1989, 1993\n\ #if 0 static char sccsid[] = "@(#)umount.c 8.8 (Berkeley) 5/8/95"; #else -__RCSID("$NetBSD: umount.c,v 1.25 1999/08/02 02:40:38 sommerfeld Exp $"); +__RCSID("$NetBSD: umount.c,v 1.26 1999/11/09 15:06:34 drochner Exp $"); #endif #endif /* not lint */ @@ -178,7 +178,7 @@ umountall(typelist) n = getmntinfo(&fs, MNT_NOWAIT); if (n == 0) - err(1, "%s", ""); + err(1, NULL); rval = 0; while (--n >= 0) { diff --git a/usr.bin/calendar/calendar.c b/usr.bin/calendar/calendar.c index 071a4fac7573..f5a7437f0ffa 100644 --- a/usr.bin/calendar/calendar.c +++ b/usr.bin/calendar/calendar.c @@ -1,4 +1,4 @@ -/* $NetBSD: calendar.c,v 1.20 1999/11/02 10:56:10 lukem Exp $ */ +/* $NetBSD: calendar.c,v 1.21 1999/11/09 15:06:34 drochner Exp $ */ /* * Copyright (c) 1989, 1993, 1994 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1989, 1993\n\ #if 0 static char sccsid[] = "@(#)calendar.c 8.4 (Berkeley) 1/7/95"; #endif -__RCSID("$NetBSD: calendar.c,v 1.20 1999/11/02 10:56:10 lukem Exp $"); +__RCSID("$NetBSD: calendar.c,v 1.21 1999/11/09 15:06:34 drochner Exp $"); #endif /* not lint */ #include @@ -108,7 +108,7 @@ main(argc, argv) case 'a': if (getuid()) { errno = EPERM; - err(1, "%s", ""); + err(1, NULL); } doall = 1; break; diff --git a/usr.bin/find/function.c b/usr.bin/find/function.c index 3a57b75c557e..0781f09ec8e7 100644 --- a/usr.bin/find/function.c +++ b/usr.bin/find/function.c @@ -1,4 +1,4 @@ -/* $NetBSD: function.c,v 1.31 1999/07/20 01:28:41 cgd Exp $ */ +/* $NetBSD: function.c,v 1.32 1999/11/09 15:06:34 drochner Exp $ */ /*- * Copyright (c) 1990, 1993 @@ -41,7 +41,7 @@ #if 0 static char sccsid[] = "from: @(#)function.c 8.10 (Berkeley) 5/4/95"; #else -__RCSID("$NetBSD: function.c,v 1.31 1999/07/20 01:28:41 cgd Exp $"); +__RCSID("$NetBSD: function.c,v 1.32 1999/11/09 15:06:34 drochner Exp $"); #endif #endif /* not lint */ @@ -1424,7 +1424,7 @@ palloc(t, f) PLAN *new; if ((new = malloc(sizeof(PLAN))) == NULL) - err(1, "%s", ""); + err(1, NULL); new->type = t; new->eval = f; new->flags = 0; diff --git a/usr.bin/finger/finger.c b/usr.bin/finger/finger.c index f413637f7267..c6c4ea516887 100644 --- a/usr.bin/finger/finger.c +++ b/usr.bin/finger/finger.c @@ -1,4 +1,4 @@ -/* $NetBSD: finger.c,v 1.13 1998/12/19 15:59:50 christos Exp $ */ +/* $NetBSD: finger.c,v 1.14 1999/11/09 15:06:35 drochner Exp $ */ /* * Copyright (c) 1989, 1993 @@ -56,7 +56,7 @@ __COPYRIGHT("@(#) Copyright (c) 1989, 1993\n\ #if 0 static char sccsid[] = "@(#)finger.c 8.5 (Berkeley) 5/4/95"; #else -__RCSID("$NetBSD: finger.c,v 1.13 1998/12/19 15:59:50 christos Exp $"); +__RCSID("$NetBSD: finger.c,v 1.14 1999/11/09 15:06:35 drochner Exp $"); #endif #endif /* not lint */ @@ -225,11 +225,7 @@ userlist(argc, argv) if ((nargv = malloc((argc+1) * sizeof(char *))) == NULL || (used = calloc(argc, sizeof(int))) == NULL) -#ifdef __GNUC__ - err(1, "%s", ""); /* XXX gcc */ -#else err(1, NULL); -#endif /* Pull out all network requests. */ for (ap = p = argv, np = nargv; *p; ++p) diff --git a/usr.bin/finger/util.c b/usr.bin/finger/util.c index eb3462790757..8186044cac45 100644 --- a/usr.bin/finger/util.c +++ b/usr.bin/finger/util.c @@ -1,4 +1,4 @@ -/* $NetBSD: util.c,v 1.14 1998/12/19 16:01:21 christos Exp $ */ +/* $NetBSD: util.c,v 1.15 1999/11/09 15:06:35 drochner Exp $ */ /* * Copyright (c) 1989, 1993 @@ -42,7 +42,7 @@ #if 0 static char sccsid[] = "@(#)util.c 8.3 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: util.c,v 1.14 1998/12/19 16:01:21 christos Exp $"); +__RCSID("$NetBSD: util.c,v 1.15 1999/11/09 15:06:35 drochner Exp $"); #endif #endif /* not lint */ @@ -206,11 +206,7 @@ enter_person(pw) if (db == NULL && (db = dbopen(NULL, O_RDWR, 0, DB_BTREE, NULL)) == NULL) -#ifdef __GNUC__ - err(1, "%s", ""); -#else err(1, NULL); -#endif key.data = (char *)pw->pw_name; key.size = strlen(pw->pw_name); @@ -268,11 +264,7 @@ palloc() PERSON *p; if ((p = malloc((u_int) sizeof(PERSON))) == NULL) -#ifdef __GNUC__ - err(1, "%s", ""); -#else err(1, NULL); -#endif return(p); } @@ -283,11 +275,7 @@ walloc(pn) WHERE *w; if ((w = malloc((u_int) sizeof(WHERE))) == NULL) -#ifdef __GNUC__ - err(1, "%s", ""); -#else err(1, NULL); -#endif if (pn->whead == NULL) pn->whead = pn->wtail = w; else { diff --git a/usr.bin/head/head.c b/usr.bin/head/head.c index 24a0c695d71c..64d756c5ba64 100644 --- a/usr.bin/head/head.c +++ b/usr.bin/head/head.c @@ -1,4 +1,4 @@ -/* $NetBSD: head.c,v 1.11 1998/12/19 16:40:29 christos Exp $ */ +/* $NetBSD: head.c,v 1.12 1999/11/09 15:06:36 drochner Exp $ */ /* * Copyright (c) 1980, 1987, 1992, 1993 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1980, 1987, 1992, 1993\n\ #if 0 static char sccsid[] = "@(#)head.c 8.2 (Berkeley) 5/4/95"; #else -__RCSID("$NetBSD: head.c,v 1.11 1998/12/19 16:40:29 christos Exp $"); +__RCSID("$NetBSD: head.c,v 1.12 1999/11/09 15:06:36 drochner Exp $"); #endif #endif /* not lint */ @@ -152,7 +152,7 @@ obsolete(argv) !isdigit((unsigned char)ap[1])) return; if ((ap = malloc(strlen(*argv) + 2)) == NULL) - err(1, "%s", ""); + err(1, NULL); ap[0] = '-'; ap[1] = 'n'; (void)strcpy(ap + 2, *argv + 1); diff --git a/usr.bin/hexdump/display.c b/usr.bin/hexdump/display.c index 2ca888e58110..5d19aa3bd047 100644 --- a/usr.bin/hexdump/display.c +++ b/usr.bin/hexdump/display.c @@ -1,4 +1,4 @@ -/* $NetBSD: display.c,v 1.7 1997/10/19 02:34:03 lukem Exp $ */ +/* $NetBSD: display.c,v 1.8 1999/11/09 15:06:36 drochner Exp $ */ /* * Copyright (c) 1989, 1993 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "@(#)display.c 8.1 (Berkeley) 6/6/93"; #else -__RCSID("$NetBSD: display.c,v 1.7 1997/10/19 02:34:03 lukem Exp $"); +__RCSID("$NetBSD: display.c,v 1.8 1999/11/09 15:06:36 drochner Exp $"); #endif #endif /* not lint */ @@ -377,5 +377,5 @@ emalloc(size) void nomem() { - err(1, "%s", ""); + err(1, NULL); } diff --git a/usr.bin/id/id.c b/usr.bin/id/id.c index 9cfdd93cf775..66b7e1b0eeea 100644 --- a/usr.bin/id/id.c +++ b/usr.bin/id/id.c @@ -41,7 +41,7 @@ __COPYRIGHT("@(#) Copyright (c) 1991, 1993\n\ #if 0 static char sccsid[] = "@(#)id.c 8.3 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: id.c,v 1.15 1999/08/17 17:37:32 mycroft Exp $"); +__RCSID("$NetBSD: id.c,v 1.16 1999/11/09 15:06:36 drochner Exp $"); #endif #endif /* not lint */ @@ -131,7 +131,7 @@ main(argc, argv) maxgroups = sysconf(_SC_NGROUPS_MAX); if ((groups = malloc((maxgroups + 1) * sizeof(gid_t))) == NULL) - err(1, "%s", ""); + err(1, NULL); if (gflag) { id = pw ? pw->pw_gid : rflag ? getgid() : getegid(); diff --git a/usr.bin/sed/process.c b/usr.bin/sed/process.c index bf595f3d8b7c..999e68e5751c 100644 --- a/usr.bin/sed/process.c +++ b/usr.bin/sed/process.c @@ -1,4 +1,4 @@ -/* $NetBSD: process.c,v 1.25 1999/05/31 04:46:33 kim Exp $ */ +/* $NetBSD: process.c,v 1.26 1999/11/09 15:06:36 drochner Exp $ */ /*- * Copyright (c) 1992 Diomidis Spinellis. @@ -42,7 +42,7 @@ #if 0 static char sccsid[] = "@(#)process.c 8.6 (Berkeley) 4/20/94"; #else -__RCSID("$NetBSD: process.c,v 1.25 1999/05/31 04:46:33 kim Exp $"); +__RCSID("$NetBSD: process.c,v 1.26 1999/11/09 15:06:36 drochner Exp $"); #endif #endif /* not lint */ @@ -532,7 +532,7 @@ regexec_e(preg, string, eflags, nomatch, slen) #ifndef REG_STARTEND if ((buf = malloc(slen + 1)) == NULL) - err(1, "%s", ""); + err(1, NULL); (void)memcpy(buf, string, slen); buf[slen] = '\0'; eval = regexec(defpreg, buf, diff --git a/usr.bin/soelim/soelim.c b/usr.bin/soelim/soelim.c index d26e22769411..c5947030a9f1 100644 --- a/usr.bin/soelim/soelim.c +++ b/usr.bin/soelim/soelim.c @@ -1,4 +1,4 @@ -/* $NetBSD: soelim.c,v 1.6 1998/02/03 04:12:24 perry Exp $ */ +/* $NetBSD: soelim.c,v 1.7 1999/11/09 15:06:36 drochner Exp $ */ /* * Copyright (c) 1980, 1993 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1980, 1993\n\ #if 0 static char sccsid[] = "@(#)soelim.c 8.1 (Berkeley) 6/6/93"; #endif -__RCSID("$NetBSD: soelim.c,v 1.6 1998/02/03 04:12:24 perry Exp $"); +__RCSID("$NetBSD: soelim.c,v 1.7 1999/11/09 15:06:36 drochner Exp $"); #endif /* not lint */ /* @@ -101,11 +101,11 @@ addpath(p, dir) p->n += 10; p->list = realloc(p->list, p->n * sizeof(p->list[0])); if (p->list == NULL) - err(1, "%s", ""); + err(1, NULL); } if ((p->list[p->c++] = strdup(dir)) == NULL) - err(1, "%s", ""); + err(1, NULL); p->list[p->c] = NULL; } diff --git a/usr.bin/su/su.c b/usr.bin/su/su.c index 0a26e7ebf286..b27f89e50ca3 100644 --- a/usr.bin/su/su.c +++ b/usr.bin/su/su.c @@ -1,4 +1,4 @@ -/* $NetBSD: su.c,v 1.35 1999/08/29 04:21:55 christos Exp $ */ +/* $NetBSD: su.c,v 1.36 1999/11/09 15:06:37 drochner Exp $ */ /* * Copyright (c) 1988 The Regents of the University of California. @@ -44,7 +44,7 @@ __COPYRIGHT( #if 0 static char sccsid[] = "@(#)su.c 8.3 (Berkeley) 4/2/94";*/ #else -__RCSID("$NetBSD: su.c,v 1.35 1999/08/29 04:21:55 christos Exp $"); +__RCSID("$NetBSD: su.c,v 1.36 1999/11/09 15:06:37 drochner Exp $"); #endif #endif /* not lint */ @@ -293,7 +293,7 @@ badlogin: p = getenv("TERM"); /* Create an empty environment */ if ((environ = malloc(sizeof(char *))) == NULL) - err(1, "%s", ""); + err(1, NULL); environ[0] = NULL; (void)setenv("PATH", _PATH_DEFPATH, 1); if (p) diff --git a/usr.bin/tset/term.c b/usr.bin/tset/term.c index 4743ca7cd70c..340afd1325ed 100644 --- a/usr.bin/tset/term.c +++ b/usr.bin/tset/term.c @@ -1,4 +1,4 @@ -/* $NetBSD: term.c,v 1.11 1998/08/25 20:59:42 ross Exp $ */ +/* $NetBSD: term.c,v 1.12 1999/11/09 15:06:37 drochner Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "@(#)term.c 8.1 (Berkeley) 6/9/93"; #endif -__RCSID("$NetBSD: term.c,v 1.11 1998/08/25 20:59:42 ross Exp $"); +__RCSID("$NetBSD: term.c,v 1.12 1999/11/09 15:06:37 drochner Exp $"); #endif /* not lint */ #include @@ -123,7 +123,7 @@ found: if ((p = getenv("TERMCAP")) != NULL && *p != '/') if (rval == -1) { if (!errno) errno = ENOENT; - err(1, "%s", ""); + err(1, NULL); } *tcapbufp = tbuf; return (ttype); diff --git a/usr.bin/w/w.c b/usr.bin/w/w.c index ef45c4766846..e68e47b3451f 100644 --- a/usr.bin/w/w.c +++ b/usr.bin/w/w.c @@ -1,4 +1,4 @@ -/* $NetBSD: w.c,v 1.32 1999/10/11 12:00:19 mrg Exp $ */ +/* $NetBSD: w.c,v 1.33 1999/11/09 15:06:37 drochner Exp $ */ /*- * Copyright (c) 1980, 1991, 1993, 1994 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1980, 1991, 1993, 1994\n\ #if 0 static char sccsid[] = "@(#)w.c 8.6 (Berkeley) 6/30/94"; #else -__RCSID("$NetBSD: w.c,v 1.32 1999/10/11 12:00:19 mrg Exp $"); +__RCSID("$NetBSD: w.c,v 1.33 1999/11/09 15:06:37 drochner Exp $"); #endif #endif /* not lint */ @@ -210,7 +210,7 @@ main(argc, argv) strncmp(utmp.ut_name, sel_user, UT_NAMESIZE) != 0)) continue; if ((ep = calloc(1, sizeof(struct entry))) == NULL) - err(1, "%s", ""); + err(1, NULL); *nextp = ep; nextp = &(ep->next); memmove(&(ep->utmp), &utmp, sizeof(struct utmp)); diff --git a/usr.bin/whereis/whereis.c b/usr.bin/whereis/whereis.c index 85cdcd010861..6e4408fa88fa 100644 --- a/usr.bin/whereis/whereis.c +++ b/usr.bin/whereis/whereis.c @@ -1,4 +1,4 @@ -/* $NetBSD: whereis.c,v 1.9 1999/03/11 10:42:43 fair Exp $ */ +/* $NetBSD: whereis.c,v 1.10 1999/11/09 15:06:37 drochner Exp $ */ /*- * Copyright (c) 1993 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1993\n\ #if 0 static char sccsid[] = "@(#)whereis.c 8.3 (Berkeley) 5/4/95"; #endif -__RCSID("$NetBSD: whereis.c,v 1.9 1999/03/11 10:42:43 fair Exp $"); +__RCSID("$NetBSD: whereis.c,v 1.10 1999/11/09 15:06:37 drochner Exp $"); #endif /* not lint */ #include @@ -99,7 +99,7 @@ main(argc, argv) if (len == 0) err(1, "user_cs_path: sysctl: zero length\n"); if ((std = malloc(len)) == NULL) - err(1, "%s", ""); + err(1, NULL); if (sysctl(mib, 2, std, &len, NULL, 0) == -1) { sverrno = errno; free(std); diff --git a/usr.bin/write/write.c b/usr.bin/write/write.c index 615e2f4a7265..b1fe13679837 100644 --- a/usr.bin/write/write.c +++ b/usr.bin/write/write.c @@ -1,4 +1,4 @@ -/* $NetBSD: write.c,v 1.15 1998/12/20 15:04:40 christos Exp $ */ +/* $NetBSD: write.c,v 1.16 1999/11/09 15:06:37 drochner Exp $ */ /* * Copyright (c) 1989, 1993 @@ -46,7 +46,7 @@ __COPYRIGHT("@(#) Copyright (c) 1989, 1993\n\ #if 0 static char sccsid[] = "@(#)write.c 8.2 (Berkeley) 4/27/95"; #else -__RCSID("$NetBSD: write.c,v 1.15 1998/12/20 15:04:40 christos Exp $"); +__RCSID("$NetBSD: write.c,v 1.16 1999/11/09 15:06:37 drochner Exp $"); #endif #endif /* not lint */ @@ -329,6 +329,6 @@ wr_fputs(s) } return; -err: err(1, "%s", ""); +err: err(1, NULL); #undef PUTC } diff --git a/usr.bin/xstr/xstr.c b/usr.bin/xstr/xstr.c index 04785fa50668..594db409d0a4 100644 --- a/usr.bin/xstr/xstr.c +++ b/usr.bin/xstr/xstr.c @@ -1,4 +1,4 @@ -/* $NetBSD: xstr.c,v 1.10 1999/04/20 13:53:53 mrg Exp $ */ +/* $NetBSD: xstr.c,v 1.11 1999/11/09 15:06:38 drochner Exp $ */ /* * Copyright (c) 1980, 1993 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1980, 1993\n\ #if 0 static char sccsid[] = "@(#)xstr.c 8.1 (Berkeley) 6/9/93"; #else -__RCSID("$NetBSD: xstr.c,v 1.10 1999/04/20 13:53:53 mrg Exp $"); +__RCSID("$NetBSD: xstr.c,v 1.11 1999/11/09 15:06:38 drochner Exp $"); #endif #endif /* not lint */ @@ -359,10 +359,10 @@ hashit(str, new) return (hp->hpt + i); } if ((hp = (struct hash *) calloc(1, sizeof (*hp))) == NULL) - err(1, "%s", ""); + err(1, NULL); hp->hpt = mesgpt; if ((hp->hstr = strdup(str)) == NULL) - err(1, "%s", ""); + err(1, NULL); mesgpt += strlen(hp->hstr) + 1; hp->hnext = hp0->hnext; hp->hnew = new; diff --git a/usr.sbin/chown/chown.c b/usr.sbin/chown/chown.c index 074f167e396f..4f8776321eb8 100644 --- a/usr.sbin/chown/chown.c +++ b/usr.sbin/chown/chown.c @@ -1,4 +1,4 @@ -/* $NetBSD: chown.c,v 1.19 1999/03/14 19:36:05 kleink Exp $ */ +/* $NetBSD: chown.c,v 1.20 1999/11/09 15:06:30 drochner Exp $ */ /* * Copyright (c) 1988, 1993, 1994 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1988, 1993, 1994\n\ #if 0 static char sccsid[] = "@(#)chown.c 8.8 (Berkeley) 4/4/94"; #else -__RCSID("$NetBSD: chown.c,v 1.19 1999/03/14 19:36:05 kleink Exp $"); +__RCSID("$NetBSD: chown.c,v 1.20 1999/11/09 15:06:30 drochner Exp $"); #endif #endif /* not lint */ @@ -164,7 +164,7 @@ main(argc, argv) a_gid(*argv); if ((ftsp = fts_open(++argv, fts_options, NULL)) == NULL) - err(EXIT_FAILURE, "%s", ""); + err(EXIT_FAILURE, NULL); for (rval = EXIT_SUCCESS; (p = fts_read(ftsp)) != NULL;) { switch (p->fts_info) { diff --git a/usr.sbin/netgroup_mkdb/util.c b/usr.sbin/netgroup_mkdb/util.c index d70a26a31abf..d119fbd45d56 100644 --- a/usr.sbin/netgroup_mkdb/util.c +++ b/usr.sbin/netgroup_mkdb/util.c @@ -1,4 +1,4 @@ -/* $NetBSD: util.c,v 1.5 1997/11/06 00:27:58 lukem Exp $ */ +/* $NetBSD: util.c,v 1.6 1999/11/09 15:06:30 drochner Exp $ */ /* * Copyright (c) 1994 Christos Zoulas @@ -33,7 +33,7 @@ #include #ifndef lint -__RCSID("$NetBSD: util.c,v 1.5 1997/11/06 00:27:58 lukem Exp $"); +__RCSID("$NetBSD: util.c,v 1.6 1999/11/09 15:06:30 drochner Exp $"); #endif #include @@ -51,8 +51,7 @@ emalloc(s) { void *ptr = malloc(s); if (ptr == NULL) - /* Crappy gcc warning! */ - err(1, "%s", ""); + err(1, NULL); return ptr; } @@ -67,8 +66,7 @@ erealloc(p, s) { void *ptr = realloc(p, s); if (ptr == NULL) - /* Crappy gcc warning! */ - err(1, "%s", ""); + err(1, NULL); return ptr; }