Localize it
This commit is contained in:
parent
298c00f5f9
commit
de34792f07
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=30921
@ -42,11 +42,11 @@ static const char copyright[] =
|
||||
static char sccsid[] = "@(#)hexdump.c 8.1 (Berkeley) 6/6/93";
|
||||
#endif
|
||||
static const char rcsid[] =
|
||||
"$Id$";
|
||||
"$Id: hexdump.c,v 1.2 1997/07/10 06:48:16 charnier Exp $";
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <locale.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
@ -65,6 +65,8 @@ main(argc, argv)
|
||||
register FS *tfs;
|
||||
char *p;
|
||||
|
||||
(void)setlocale(LC_CTYPE, "");
|
||||
|
||||
if (!(p = rindex(argv[0], 'o')) || strcmp(p, "od"))
|
||||
newsyntax(argc, &argv);
|
||||
else
|
||||
|
@ -36,7 +36,7 @@
|
||||
static char sccsid[] = "@(#)odsyntax.c 8.2 (Berkeley) 5/4/95";
|
||||
#endif
|
||||
static const char rcsid[] =
|
||||
"$Id$";
|
||||
"$Id: odsyntax.c,v 1.5 1997/07/10 06:48:21 charnier Exp $";
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/types.h>
|
||||
@ -161,9 +161,8 @@ odoffset(argc, argvp)
|
||||
char ***argvp;
|
||||
{
|
||||
extern off_t skip;
|
||||
register char *num, *p;
|
||||
unsigned char *p, *num, *end;
|
||||
int base;
|
||||
char *end;
|
||||
|
||||
/*
|
||||
* The offset syntax of od(1) was genuinely bizarre. First, if
|
||||
@ -215,7 +214,7 @@ odoffset(argc, argvp)
|
||||
base = 10;
|
||||
}
|
||||
|
||||
skip = strtol(num, &end, base ? base : 8);
|
||||
skip = strtol(num, (char **)&end, base ? base : 8);
|
||||
|
||||
/* if end isn't the same as p, we got a non-octal digit */
|
||||
if (end != p) {
|
||||
|
@ -36,7 +36,7 @@
|
||||
static char sccsid[] = "@(#)parse.c 8.1 (Berkeley) 6/6/93";
|
||||
#endif
|
||||
static const char rcsid[] =
|
||||
"$Id$";
|
||||
"$Id: parse.c,v 1.2 1997/07/10 06:48:24 charnier Exp $";
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/types.h>
|
||||
@ -55,7 +55,7 @@ void
|
||||
addfile(name)
|
||||
char *name;
|
||||
{
|
||||
register char *p;
|
||||
register unsigned char *p;
|
||||
FILE *fp;
|
||||
int ch;
|
||||
char buf[2048 + 1];
|
||||
@ -81,11 +81,10 @@ void
|
||||
add(fmt)
|
||||
char *fmt;
|
||||
{
|
||||
register char *p;
|
||||
unsigned char *p, *savep;
|
||||
static FS **nextfs;
|
||||
FS *tfs;
|
||||
FU *tfu, **nextfu;
|
||||
char *savep;
|
||||
|
||||
/* start new linked list of format units */
|
||||
tfs = emalloc(sizeof(FS));
|
||||
@ -158,7 +157,7 @@ size(fs)
|
||||
{
|
||||
register FU *fu;
|
||||
register int bcnt, cursize;
|
||||
register char *fmt;
|
||||
register unsigned char *fmt;
|
||||
int prec;
|
||||
|
||||
/* figure out the data block size needed for each format unit */
|
||||
@ -213,8 +212,8 @@ rewrite(fs)
|
||||
enum { NOTOKAY, USEBCNT, USEPREC } sokay;
|
||||
register PR *pr, **nextpr;
|
||||
register FU *fu;
|
||||
register char *p1, *p2;
|
||||
char savech, *fmtp, cs[3];
|
||||
unsigned char *p1, *p2, *fmtp;
|
||||
char savech, cs[3];
|
||||
int nconv, prec;
|
||||
|
||||
for (fu = fs->nextfu; fu; fu = fu->nextfu) {
|
||||
|
Loading…
Reference in New Issue
Block a user