diff options
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/calendar/calendar.c | 14 | ||||
-rw-r--r-- | usr.bin/lock/lock.c | 6 | ||||
-rw-r--r-- | usr.bin/oldrdist/server.c | 8 | ||||
-rw-r--r-- | usr.bin/rdist/common.c | 22 | ||||
-rw-r--r-- | usr.bin/skeyinit/skeyinit.c | 4 | ||||
-rw-r--r-- | usr.bin/sup/src/supfilesrv.c | 4 | ||||
-rw-r--r-- | usr.bin/top/username.c | 4 |
7 files changed, 31 insertions, 31 deletions
diff --git a/usr.bin/calendar/calendar.c b/usr.bin/calendar/calendar.c index d9288ef3ffc..9ea6589bdd3 100644 --- a/usr.bin/calendar/calendar.c +++ b/usr.bin/calendar/calendar.c @@ -1,4 +1,4 @@ -/* $OpenBSD: calendar.c,v 1.17 2002/02/16 21:27:44 millert Exp $ */ +/* $OpenBSD: calendar.c,v 1.18 2002/06/23 03:07:21 deraadt Exp $ */ /* * Copyright (c) 1989, 1993, 1994 @@ -43,7 +43,7 @@ static const char copyright[] = #if 0 static const char sccsid[] = "@(#)calendar.c 8.3 (Berkeley) 3/25/94"; #else -static char rcsid[] = "$OpenBSD: calendar.c,v 1.17 2002/02/16 21:27:44 millert Exp $"; +static char rcsid[] = "$OpenBSD: calendar.c,v 1.18 2002/06/23 03:07:21 deraadt Exp $"; #endif #endif /* not lint */ @@ -190,8 +190,8 @@ main(argc, argv) (void)setlocale(LC_ALL, ""); if (setusercontext(NULL, pw, pw->pw_uid, LOGIN_SETALL ^ LOGIN_SETLOGIN)) - err(1, "unable to set user context (uid %d)", - (int)pw->pw_uid); + err(1, "unable to set user context (uid %u)", + pw->pw_uid); if (acstat) { if (chdir(pw->pw_dir) || stat(calendarFile, &sbuf) != 0 || @@ -233,11 +233,11 @@ main(argc, argv) * if there's only a zombie now. */ (void)kill(kid, SIGTERM); - warnx("uid %d did not finish in time", (int)pw->pw_uid); + warnx("uid %u did not finish in time", pw->pw_uid); } if (time(NULL) - t >= SECSPERDAY) - errx(2, "'calendar -a' took more than a day; stopped at uid %d", - (int)pw->pw_uid); + errx(2, "'calendar -a' took more than a day; stopped at uid %u", + pw->pw_uid); } for (;;) { deadkid = waitpid(-1, &kidstat, WNOHANG); diff --git a/usr.bin/lock/lock.c b/usr.bin/lock/lock.c index 8286d42a054..ab321a2d24c 100644 --- a/usr.bin/lock/lock.c +++ b/usr.bin/lock/lock.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lock.c,v 1.16 2002/05/08 18:04:43 millert Exp $ */ +/* $OpenBSD: lock.c,v 1.17 2002/06/23 03:07:21 deraadt Exp $ */ /* $NetBSD: lock.c,v 1.8 1996/05/07 18:32:31 jtc Exp $ */ /* @@ -47,7 +47,7 @@ static char copyright[] = #if 0 static char sccsid[] = "@(#)lock.c 8.1 (Berkeley) 6/6/93"; #endif -static char rcsid[] = "$OpenBSD: lock.c,v 1.16 2002/05/08 18:04:43 millert Exp $"; +static char rcsid[] = "$OpenBSD: lock.c,v 1.17 2002/06/23 03:07:21 deraadt Exp $"; #endif /* not lint */ /* @@ -109,7 +109,7 @@ main(argc, argv) no_timeout = 0; if (!(pw = getpwuid(getuid()))) - errx(1, "unknown uid %d.", getuid()); + errx(1, "unknown uid %u.", getuid()); lc = login_getclass(pw->pw_class); diff --git a/usr.bin/oldrdist/server.c b/usr.bin/oldrdist/server.c index 973fea3ab71..33ff3cb3df3 100644 --- a/usr.bin/oldrdist/server.c +++ b/usr.bin/oldrdist/server.c @@ -1,4 +1,4 @@ -/* $OpenBSD: server.c,v 1.19 2002/06/12 06:07:16 mpech Exp $ */ +/* $OpenBSD: server.c,v 1.20 2002/06/23 03:07:21 deraadt Exp $ */ /* * Copyright (c) 1983, 1993 @@ -35,7 +35,7 @@ #ifndef lint /* from: static char sccsid[] = "@(#)server.c 8.1 (Berkeley) 6/9/93"; */ -static char *rcsid = "$OpenBSD: server.c,v 1.19 2002/06/12 06:07:16 mpech Exp $"; +static char *rcsid = "$OpenBSD: server.c,v 1.20 2002/06/23 03:07:21 deraadt Exp $"; #endif /* not lint */ #include <sys/wait.h> @@ -392,14 +392,14 @@ sendf(rname, opts) if (pw == NULL || pw->pw_uid != stb.st_uid) if ((pw = getpwuid(stb.st_uid)) == NULL) { - log(lfp, "%s: no password entry for uid %d \n", + log(lfp, "%s: no password entry for uid %u \n", target, stb.st_uid); pw = NULL; (void) snprintf(user, sizeof(user), ":%lu", stb.st_uid); } if (gr == NULL || gr->gr_gid != stb.st_gid) if ((gr = getgrgid(stb.st_gid)) == NULL) { - log(lfp, "%s: no name for group %d\n", + log(lfp, "%s: no name for group %u\n", target, stb.st_gid); gr = NULL; (void) snprintf(group, sizeof(group), ":%lu", diff --git a/usr.bin/rdist/common.c b/usr.bin/rdist/common.c index beafd3b257f..d4e72c20cb9 100644 --- a/usr.bin/rdist/common.c +++ b/usr.bin/rdist/common.c @@ -1,4 +1,4 @@ -/* $OpenBSD: common.c,v 1.15 2002/06/12 06:07:16 mpech Exp $ */ +/* $OpenBSD: common.c,v 1.16 2002/06/23 03:07:22 deraadt Exp $ */ /* * Copyright (c) 1983 Regents of the University of California. @@ -39,7 +39,7 @@ static char RCSid[] = "$From: common.c,v 6.82 1998/03/23 23:27:33 michaelc Exp $"; #else static char RCSid[] = -"$OpenBSD: common.c,v 1.15 2002/06/12 06:07:16 mpech Exp $"; +"$OpenBSD: common.c,v 1.16 2002/06/23 03:07:22 deraadt Exp $"; #endif static char sccsid[] = "@(#)common.c"; @@ -156,7 +156,7 @@ extern int init(argc, argv, envp) pw = getpwuid(userid = getuid()); if (pw == NULL) { - error("Your user id (%d) is not known to this system.", + error("Your user id (%u) is not known to this system.", getuid()); return(-1); } @@ -552,7 +552,7 @@ extern char *getusername(uid, file, opts) * do the opts check. */ if (IS_ON(opts, DO_NUMCHKOWNER)) { - (void) sprintf(buf, ":%d", uid); + (void) sprintf(buf, ":%u", uid); return(buf); } @@ -566,8 +566,8 @@ extern char *getusername(uid, file, opts) if ((pwd = getpwuid(uid)) == NULL) { message(MT_WARNING, - "%s: No password entry for uid %d", file, uid); - (void) sprintf(buf, ":%d", uid); + "%s: No password entry for uid %u", file, uid); + (void) sprintf(buf, ":%u", uid); } else (void) strcpy(buf, pwd->pw_name); @@ -591,7 +591,7 @@ extern char *getgroupname(gid, file, opts) * do the opts check. */ if (IS_ON(opts, DO_NUMCHKGROUP)) { - (void) sprintf(buf, ":%d", gid); + (void) sprintf(buf, ":%u", gid); return(buf); } @@ -604,8 +604,8 @@ extern char *getgroupname(gid, file, opts) lastgid = gid; if ((grp = (struct group *)getgrgid(gid)) == NULL) { - message(MT_WARNING, "%s: No name for group %d", file, gid); - (void) sprintf(buf, ":%d", gid); + message(MT_WARNING, "%s: No name for group %u", file, gid); + (void) sprintf(buf, ":%u", gid); } else (void) strcpy(buf, grp->gr_name); @@ -732,7 +732,7 @@ extern int becomeuser() #endif /* HAVE_SAVED_IDS */ if (r < 0) - error("becomeuser %d failed: %s (ruid = %d euid = %d)", + error("becomeuser %d failed: %s (ruid = %u euid = %u)", userid, SYSERR, getuid(), geteuid()); return(r); @@ -754,7 +754,7 @@ extern int becomeroot() #endif /* HAVE_SAVED_IDS */ if (r < 0) - error("becomeroot failed: %s (ruid = %d euid = %d)", + error("becomeroot failed: %s (ruid = %u euid = %u)", SYSERR, getuid(), geteuid()); return(r); diff --git a/usr.bin/skeyinit/skeyinit.c b/usr.bin/skeyinit/skeyinit.c index 00b7547c259..a85728a349d 100644 --- a/usr.bin/skeyinit/skeyinit.c +++ b/usr.bin/skeyinit/skeyinit.c @@ -1,4 +1,4 @@ -/* $OpenBSD: skeyinit.c,v 1.39 2002/06/07 21:53:43 millert Exp $ */ +/* $OpenBSD: skeyinit.c,v 1.40 2002/06/23 03:07:22 deraadt Exp $ */ /* OpenBSD S/Key (skeyinit.c) * @@ -80,7 +80,7 @@ main(int argc, char **argv) *p = '\0'; if ((pp = getpwuid(getuid())) == NULL) - err(1, "no user with uid %d", getuid()); + err(1, "no user with uid %u", getuid()); (void)strcpy(me, pp->pw_name); if ((pp = getpwnam(me)) == NULL) diff --git a/usr.bin/sup/src/supfilesrv.c b/usr.bin/sup/src/supfilesrv.c index a762ab594c5..e8fbbf149b4 100644 --- a/usr.bin/sup/src/supfilesrv.c +++ b/usr.bin/sup/src/supfilesrv.c @@ -1,4 +1,4 @@ -/* $OpenBSD: supfilesrv.c,v 1.29 2002/06/12 06:07:16 mpech Exp $ */ +/* $OpenBSD: supfilesrv.c,v 1.30 2002/06/23 03:07:22 deraadt Exp $ */ /* * Copyright (c) 1992 Carnegie Mellon University @@ -1691,7 +1691,7 @@ changeuid(namep, passwordp, fileuid, filegid) pwd = getpwuid(fileuid); if (pwd == NULL) { (void) snprintf(errbuf, sizeof errbuf, - "Reason: Unknown user id %d", fileuid); + "Reason: Unknown user id %u", fileuid); return (errbuf); } grp = getgrgid(filegid); diff --git a/usr.bin/top/username.c b/usr.bin/top/username.c index 4178304e733..01ecd8046ef 100644 --- a/usr.bin/top/username.c +++ b/usr.bin/top/username.c @@ -1,4 +1,4 @@ -/* $OpenBSD: username.c,v 1.5 2002/02/16 21:27:55 millert Exp $ */ +/* $OpenBSD: username.c,v 1.6 2002/06/23 03:07:22 deraadt Exp $ */ /* * Top users/processes display for Unix @@ -117,7 +117,7 @@ int wecare; /* 1 = enter it always, 0 = nice to have */ int hashindex; #ifdef DEBUG - fprintf(stderr, "enter_hash(%d, %s, %d)\n", uid, name, wecare); + fprintf(stderr, "enter_hash(%u, %s, %d)\n", uid, name, wecare); #endif hashindex = hashit(uid); |