Source-Changes-HG archive

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

[src/trunk]: src/bin/pax Cast size_t's to (int) when printing as %d; appeases...



details:   https://anonhg.NetBSD.org/src/rev/94cb2444582e
branches:  trunk
changeset: 516631:94cb2444582e
user:      lukem <lukem%NetBSD.org@localhost>
date:      Fri Oct 26 15:58:43 2001 +0000

description:
Cast size_t's to (int) when printing as %d; appeases the sparc port.
Found by Rob Windsor in [bin/14362].

diffstat:

 bin/pax/ftree.c |  12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diffs (47 lines):

diff -r 6c1ad70454d0 -r 94cb2444582e bin/pax/ftree.c
--- a/bin/pax/ftree.c   Fri Oct 26 14:44:13 2001 +0000
+++ b/bin/pax/ftree.c   Fri Oct 26 15:58:43 2001 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ftree.c,v 1.13 2001/10/25 13:54:54 lukem Exp $ */
+/*     $NetBSD: ftree.c,v 1.14 2001/10/26 15:58:43 lukem Exp $ */
 
 /*-
  * Copyright (c) 1992 Keith Muller.
@@ -78,7 +78,7 @@
 #if 0
 static char sccsid[] = "@(#)ftree.c    8.2 (Berkeley) 4/18/94";
 #else
-__RCSID("$NetBSD: ftree.c,v 1.13 2001/10/25 13:54:54 lukem Exp $");
+__RCSID("$NetBSD: ftree.c,v 1.14 2001/10/26 15:58:43 lukem Exp $");
 #endif
 #endif /* not lint */
 
@@ -428,8 +428,8 @@
                if (snprintf(curpath, sizeof(curpath), "%s%s%s",
                    curdir, curdirlen ? "/" : "", ftnode->name)
                    >= sizeof(curpath)) {
-                       tty_warn(1, "line %d: %s: %s",
-                           ftnode->lineno, curdir, strerror(ENAMETOOLONG));
+                       tty_warn(1, "line %d: %s: %s", (int)ftnode->lineno,
+                           curdir, strerror(ENAMETOOLONG));
                        return (-1);
                }
                ftnode->flags |= F_VISIT;       /* mark node visited */
@@ -449,7 +449,7 @@
 #define NODETEST(t, m)                                                 \
                        if (!(t)) {                                     \
                                tty_warn(1, "line %d: %s: %s not specified", \
-                                   ftnode->lineno, ftent->fts_path, m); \
+                                   (int)ftnode->lineno, ftent->fts_path, m); \
                                return(-1);                             \
                        }
                        statbuf.st_mode = nodetoino(ftnode->type);
@@ -470,7 +470,7 @@
                    nodetoino(ftnode->type) != (statbuf.st_mode & S_IFMT)) {
                        tty_warn(1,
                            "line %d: %s: type mismatch: specfile %s, tree %s",
-                           ftnode->lineno, ftent->fts_path,
+                           (int)ftnode->lineno, ftent->fts_path,
                            inotype(nodetoino(ftnode->type)),
                            inotype(statbuf.st_mode));
                        return(-1);



Home | Main Index | Thread Index | Old Index