use %ll_ instead of the less standard %q_

This commit is contained in:
lukem 2001-01-04 23:05:54 +00:00
parent c792f5941a
commit c2b84904ae
13 changed files with 47 additions and 46 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: misc.c,v 1.5 1997/10/19 14:06:01 mrg Exp $ */
/* $NetBSD: misc.c,v 1.6 2001/01/04 23:05:54 lukem Exp $ */
/*-
* Copyright (c) 1991, 1993, 1994
@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)misc.c 8.3 (Berkeley) 4/2/94";
#else
__RCSID("$NetBSD: misc.c,v 1.5 1997/10/19 14:06:01 mrg Exp $");
__RCSID("$NetBSD: misc.c,v 1.6 2001/01/04 23:05:54 lukem Exp $");
#endif
#endif /* not lint */
@ -65,7 +65,7 @@ diffmsg(file1, file2, byte, line)
off_t byte, line;
{
if (!sflag)
(void)printf("%s %s differ: char %qd, line %qd\n",
(void)printf("%s %s differ: char %lld, line %lld\n",
file1, file2, (long long)byte, (long long)line);
exit(DIFF_EXIT);
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: regular.c,v 1.10 2000/07/27 02:58:57 mycroft Exp $ */
/* $NetBSD: regular.c,v 1.11 2001/01/04 23:05:54 lukem Exp $ */
/*-
* Copyright (c) 1991, 1993, 1994
@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)regular.c 8.3 (Berkeley) 4/2/94";
#else
__RCSID("$NetBSD: regular.c,v 1.10 2000/07/27 02:58:57 mycroft Exp $");
__RCSID("$NetBSD: regular.c,v 1.11 2001/01/04 23:05:54 lukem Exp $");
#endif
#endif /* not lint */
@ -98,7 +98,7 @@ mmap_failed:
if ((ch = *p1) != *p2) {
if (lflag) {
dfound = 1;
(void)printf("%6qd %3o %3o\n", (long long)byte,
(void)printf("%6lld %3o %3o\n", (long long)byte,
ch, *p2);
} else
diffmsg(file1, file2, byte, line);

View File

@ -1,4 +1,4 @@
/* $NetBSD: special.c,v 1.6 1998/08/25 20:59:36 ross Exp $ */
/* $NetBSD: special.c,v 1.7 2001/01/04 23:05:54 lukem Exp $ */
/*-
* Copyright (c) 1991, 1993, 1994
@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)special.c 8.3 (Berkeley) 4/2/94";
#else
__RCSID("$NetBSD: special.c,v 1.6 1998/08/25 20:59:36 ross Exp $");
__RCSID("$NetBSD: special.c,v 1.7 2001/01/04 23:05:54 lukem Exp $");
#endif
#endif /* not lint */
@ -84,7 +84,7 @@ c_special(fd1, file1, skip1, fd2, file2, skip2)
if (ch1 != ch2) {
if (lflag) {
dfound = 1;
(void)printf("%6qd %3o %3o\n", (long long)byte,
(void)printf("%6lld %3o %3o\n", (long long)byte,
ch1, ch2);
} else
diffmsg(file1, file2, byte, line);

View File

@ -1,4 +1,4 @@
/* $NetBSD: du.c,v 1.16 2000/12/30 16:00:33 hubertf Exp $ */
/* $NetBSD: du.c,v 1.17 2001/01/04 23:05:54 lukem Exp $ */
/*
* Copyright (c) 1989, 1993, 1994
@ -46,7 +46,7 @@ __COPYRIGHT("@(#) Copyright (c) 1989, 1993, 1994\n\
#if 0
static char sccsid[] = "@(#)du.c 8.5 (Berkeley) 5/4/95";
#else
__RCSID("$NetBSD: du.c,v 1.16 2000/12/30 16:00:33 hubertf Exp $");
__RCSID("$NetBSD: du.c,v 1.17 2001/01/04 23:05:54 lukem Exp $");
#endif
#endif /* not lint */
@ -203,7 +203,7 @@ main(argc, argv)
* the root of a traversal, display the total.
*/
if (listfiles || !p->fts_level)
(void)printf("%qd\t%s\n", (long long)
(void)printf("%lld\t%s\n", (long long)
howmany(p->fts_statp->st_blocks, blocksize),
p->fts_path);
p->fts_parent->fts_number += p->fts_statp->st_blocks;

View File

@ -1,4 +1,4 @@
/* $NetBSD: ls.c,v 1.13 1998/11/06 23:21:38 christos Exp $ */
/* $NetBSD: ls.c,v 1.14 2001/01/04 23:05:55 lukem Exp $ */
/*
* Copyright (c) 1989, 1993
@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "from: @(#)ls.c 8.1 (Berkeley) 6/6/93";
#else
__RCSID("$NetBSD: ls.c,v 1.13 1998/11/06 23:21:38 christos Exp $");
__RCSID("$NetBSD: ls.c,v 1.14 2001/01/04 23:05:55 lukem Exp $");
#endif
#endif /* not lint */
@ -73,7 +73,7 @@ printlong(name, accpath, sb)
{
char modep[15];
(void)printf("%7lu %6qd ", (u_long)sb->st_ino,
(void)printf("%7lu %6lld ", (u_long)sb->st_ino,
(long long)sb->st_blocks);
(void)strmode(sb->st_mode, modep);
(void)printf("%s %3lu %-*s %-*s ", modep, (unsigned long)sb->st_nlink,
@ -84,7 +84,7 @@ printlong(name, accpath, sb)
(void)printf("%3d,%5d ", major(sb->st_rdev),
minor(sb->st_rdev));
else
(void)printf("%9qd ", (long long)sb->st_size);
(void)printf("%9lld ", (long long)sb->st_size);
printtime(sb->st_mtime);
(void)printf("%s", name);
if (S_ISLNK(sb->st_mode))

View File

@ -1,4 +1,4 @@
/* $NetBSD: fstat.c,v 1.44 2000/08/14 09:17:11 enami Exp $ */
/* $NetBSD: fstat.c,v 1.45 2001/01/04 23:05:55 lukem Exp $ */
/*-
* Copyright (c) 1988, 1993
@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1988, 1993\n\
#if 0
static char sccsid[] = "@(#)fstat.c 8.3 (Berkeley) 5/2/95";
#else
__RCSID("$NetBSD: fstat.c,v 1.44 2000/08/14 09:17:11 enami Exp $");
__RCSID("$NetBSD: fstat.c,v 1.45 2001/01/04 23:05:55 lukem Exp $");
#endif
#endif /* not lint */
@ -516,7 +516,7 @@ vtrans(vp, i, flag)
break;
}
default:
printf(" %6qd", (long long)fst.size);
printf(" %6lld", (long long)fst.size);
}
rw[0] = '\0';
if (flag & FREAD)

View File

@ -1,4 +1,4 @@
/* $NetBSD: less.h,v 1.3 1999/04/06 05:57:35 mrg Exp $ */
/* $NetBSD: less.h,v 1.4 2001/01/04 23:05:55 lukem Exp $ */
/*
* Copyright (c) 1984,1985,1989,1994,1995,1996,1999 Mark Nudelman
@ -141,7 +141,7 @@ void free();
* Special types and constants.
*/
typedef off_t POSITION;
#define PR_POSITION "%qd"
#define PR_POSITION "%lld"
#define PR_CAST long long
#define MAX_PRINT_POSITION 20
#define MAX_PRINT_INT 10

View File

@ -1,4 +1,4 @@
/* $NetBSD: server.c,v 1.19 2000/10/11 14:46:16 is Exp $ */
/* $NetBSD: server.c,v 1.20 2001/01/04 23:05:55 lukem Exp $ */
/*
* Copyright (c) 1983, 1993
@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)server.c 8.1 (Berkeley) 6/9/93";
#else
__RCSID("$NetBSD: server.c,v 1.19 2000/10/11 14:46:16 is Exp $");
__RCSID("$NetBSD: server.c,v 1.20 2001/01/04 23:05:55 lukem Exp $");
#endif
#endif /* not lint */
@ -445,7 +445,7 @@ sendf(rname, opts)
return;
}
}
(void) snprintf(buf, sizeof(buf), "K%o %o %qd %ld %s %s %s\n",
(void) snprintf(buf, sizeof(buf), "K%o %o %lld %ld %s %s %s\n",
opts, stb.st_mode & 07777, (unsigned long long)stb.st_size,
(u_long)stb.st_mtime, protoname(), protogroup(), rname);
if (debug)
@ -504,7 +504,7 @@ sendf(rname, opts)
error("%s: %s\n", target, strerror(errno));
return;
}
(void)snprintf(buf, sizeof(buf), "R%o %o %qd %lu %s %s %s\n", opts,
(void)snprintf(buf, sizeof(buf), "R%o %o %lld %lu %s %s %s\n", opts,
stb.st_mode & 07777, (unsigned long long)stb.st_size,
(u_long)stb.st_mtime, protoname(), protogroup(), rname);
if (debug)
@ -713,7 +713,7 @@ query(name)
switch (stb.st_mode & S_IFMT) {
case S_IFREG:
(void)snprintf(buf, sizeof(buf), "Y%qd %ld\n",
(void)snprintf(buf, sizeof(buf), "Y%lld %ld\n",
(unsigned long long)stb.st_size, (u_long)stb.st_mtime);
if (write(rem, buf, strlen(buf)) < 0)
error("write to remote failed: %s\n", strerror(errno));

View File

@ -1,4 +1,4 @@
/* $NetBSD: reverse.c,v 1.11 1999/07/21 06:38:50 cgd Exp $ */
/* $NetBSD: reverse.c,v 1.12 2001/01/04 23:05:56 lukem Exp $ */
/*-
* Copyright (c) 1991, 1993
@ -41,7 +41,7 @@
#if 0
static char sccsid[] = "@(#)reverse.c 8.1 (Berkeley) 6/6/93";
#endif
__RCSID("$NetBSD: reverse.c,v 1.11 1999/07/21 06:38:50 cgd Exp $");
__RCSID("$NetBSD: reverse.c,v 1.12 2001/01/04 23:05:56 lukem Exp $");
#endif /* not lint */
#include <sys/param.h>
@ -227,7 +227,7 @@ r_buf(fp)
if (enomem) {
(void)fprintf(stderr,
"tail: warning: %qd bytes discarded\n", (long long)enomem);
"tail: warning: %lld bytes discarded\n", (long long)enomem);
rval = 1;
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: tcopy.c,v 1.10 2000/07/07 15:13:25 itojun Exp $ */
/* $NetBSD: tcopy.c,v 1.11 2001/01/04 23:05:56 lukem Exp $ */
/*
* Copyright (c) 1985, 1987, 1993, 1995
@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1985, 1987, 1993\n\
#if 0
static char sccsid[] = "@(#)tcopy.c 8.3 (Berkeley) 1/23/95";
#endif
__RCSID("$NetBSD: tcopy.c,v 1.10 2000/07/07 15:13:25 itojun Exp $");
__RCSID("$NetBSD: tcopy.c,v 1.11 2001/01/04 23:05:56 lukem Exp $");
#endif /* not lint */
#include <sys/types.h>
@ -211,7 +211,7 @@ r1: guesslen = 0;
break;
}
fprintf(msg,
"file %d: eof after %ld records: %qd bytes\n",
"file %d: eof after %ld records: %lld bytes\n",
filen, record, (long long)size);
needeof = 1;
filen++;
@ -221,7 +221,7 @@ r1: guesslen = 0;
}
lastnread = nread;
}
fprintf(msg, "total length: %qd bytes\n", (long long)tsize);
fprintf(msg, "total length: %lld bytes\n", (long long)tsize);
(void)signal(SIGINT, oldsig);
if (op == COPY || op == COPYVERIFY) {
writeop(outp, MTWEOF);
@ -302,7 +302,7 @@ intr(signo)
fprintf(msg, "record %ld\n", lastrec);
}
fprintf(msg, "interrupt at file %d: record %ld\n", filen, record);
fprintf(msg, "total length: %qd bytes\n", (long long)(tsize + size));
fprintf(msg, "total length: %lld bytes\n", (long long)(tsize + size));
exit(1);
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: search.c,v 1.4 2000/03/17 02:23:17 christos Exp $ */
/* $NetBSD: search.c,v 1.5 2001/01/04 23:05:56 lukem Exp $ */
/*-
* Copyright (c) 1992, 1993, 1994
@ -290,8 +290,8 @@ f_search(sp, fm, rm, ptrn, eptrn, flags)
search_msg(sp, S_WRAP);
#if defined(DEBUG) && 0
TRACE(sp, "F search: %qu to %qu\n",
match[0].rm_so, match[0].rm_eo);
TRACE(sp, "F search: %llu to %llu\n",
(long long)match[0].rm_so, (long long)match[0].rm_eo);
#endif
rm->lno = lno;
rm->cno = match[0].rm_so;
@ -413,7 +413,8 @@ b_search(sp, fm, rm, ptrn, eptrn, flags)
#endif
#if defined(DEBUG) && 0
TRACE(sp, "B search: %lu from 0 to %qu\n", lno, match[0].rm_eo);
TRACE(sp, "B search: %lu from 0 to %llu\n", lno,
(long long)match[0].rm_eo);
#endif
/* Search the line. */
#ifdef REG_STARTEND
@ -447,8 +448,8 @@ b_search(sp, fm, rm, ptrn, eptrn, flags)
search_msg(sp, S_WRAP);
#if defined(DEBUG) && 0
TRACE(sp, "B found: %qu to %qu\n",
match[0].rm_so, match[0].rm_eo);
TRACE(sp, "B found: %llu to %llu\n",
(long long)match[0].rm_so, (long long)match[0].rm_eo);
#endif
/*
* We now have the first match on the line. Step through the

View File

@ -1,6 +1,6 @@
#ifndef lint
/*static char yysccsid[] = "from: @(#)yaccpar 1.9 (Berkeley) 02/21/93";*/
static char rcsid[] = "$NetBSD: ftp.tab.c,v 1.6 1997/01/09 20:23:31 tls Exp $";
static char rcsid[] = "$NetBSD: ftp.tab.c,v 1.7 2001/01/04 23:05:57 lukem Exp $";
#endif
#define YYBYACC 1
#define YYMAJOR 1
@ -873,7 +873,7 @@ char *filename;
(stbuf.st_mode&S_IFMT) != S_IFREG)
reply(550, "%s: not a plain file.", filename);
else
reply(213, "%qu", stbuf.st_size);
reply(213, "%llu", (long long)stbuf.st_size);
break;}
case TYPE_A: {
FILE *fin;

View File

@ -1,4 +1,4 @@
/* $NetBSD: ftp.y,v 1.5 1997/01/09 20:23:33 tls Exp $ */
/* $NetBSD: ftp.y,v 1.6 2001/01/04 23:05:57 lukem Exp $ */
/*
* Copyright (c) 1985, 1988 Regents of the University of California.
@ -17,7 +17,7 @@
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
* from: @(#)ftpcmd.y 5.20.1.1 (Berkeley) 3/2/89
* $NetBSD: ftp.y,v 1.5 1997/01/09 20:23:33 tls Exp $
* $NetBSD: ftp.y,v 1.6 2001/01/04 23:05:57 lukem Exp $
*/
/*
@ -29,7 +29,7 @@
#ifndef lint
/*static char sccsid[] = "from: @(#)ftpcmd.y 5.20.1.1 (Berkeley) 3/2/89";*/
static char rcsid[] = "$NetBSD: ftp.y,v 1.5 1997/01/09 20:23:33 tls Exp $";
static char rcsid[] = "$NetBSD: ftp.y,v 1.6 2001/01/04 23:05:57 lukem Exp $";
#endif /* not lint */
#include <sys/param.h>
@ -1151,7 +1151,7 @@ char *filename;
(stbuf.st_mode&S_IFMT) != S_IFREG)
reply(550, "%s: not a plain file.", filename);
else
reply(213, "%qu", stbuf.st_size);
reply(213, "%llu", (long long)stbuf.st_size);
break;}
case TYPE_A: {
FILE *fin;