diff options
author | rsc <devnull@localhost> | 2006-04-01 19:24:03 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2006-04-01 19:24:03 +0000 |
commit | cbeb0b26e4c7caa8d1b47de791a7418dc20a4567 (patch) | |
tree | e0f7e445de1aa22a42ef873dc4b1118a8105ae93 /src/cmd/troff | |
parent | 226d80b8213821af0cbf092d1507c52b504fd368 (diff) | |
download | plan9port-cbeb0b26e4c7caa8d1b47de791a7418dc20a4567.tar.gz plan9port-cbeb0b26e4c7caa8d1b47de791a7418dc20a4567.tar.bz2 plan9port-cbeb0b26e4c7caa8d1b47de791a7418dc20a4567.zip |
Use gcc -ansi -pedantic in 9c. Fix many non-C89-isms.
Diffstat (limited to 'src/cmd/troff')
-rw-r--r-- | src/cmd/troff/hytab.c | 8 | ||||
-rw-r--r-- | src/cmd/troff/mkfile | 2 | ||||
-rw-r--r-- | src/cmd/troff/n1.c | 4 | ||||
-rw-r--r-- | src/cmd/troff/n2.c | 1 | ||||
-rw-r--r-- | src/cmd/troff/n7.c | 1 | ||||
-rw-r--r-- | src/cmd/troff/ni.c | 6 | ||||
-rw-r--r-- | src/cmd/troff/suftab.c | 2 |
7 files changed, 13 insertions, 11 deletions
diff --git a/src/cmd/troff/hytab.c b/src/cmd/troff/hytab.c index 623637fc..c2b06624 100644 --- a/src/cmd/troff/hytab.c +++ b/src/cmd/troff/hytab.c @@ -35,7 +35,7 @@ Uchar hxx[26][13] = { 0140,0000,0020,0001,0020,0000,0000,0100,0001,0000,0300,0000,0000, 0000,0000,0000,0000,0000,0000,0000,0000,0000,0000,0000,0000,0000, 0106,0041,0040,0147,0040,0000,0063,0041,0001,0102,0160,0002,0002, - 0300,0000,0040,0017,0140,0017,0000,0240,0000,0000,0140,0000,0120, + 0300,0000,0040,0017,0140,0017,0000,0240,0000,0000,0140,0000,0120 }; Uchar bxxh[26][13] = { @@ -64,7 +64,7 @@ Uchar bxxh[26][13] = { 0020,0000,0000,0000,0020,0000,0000,0000,0000,0000,0000,0000,0060, 0140,0000,0160,0000,0200,0000,0000,0140,0000,0000,0000,0000,0240, 0065,0042,0060,0200,0000,0210,0222,0146,0006,0204,0220,0012,0003, - 0240,0000,0020,0000,0120,0000,0000,0200,0000,0000,0200,0000,0240, + 0240,0000,0020,0000,0120,0000,0000,0200,0000,0000,0200,0000,0240 }; Uchar xhx[26][13] = { @@ -93,7 +93,7 @@ Uchar xhx[26][13] = { 0037,0232,0157,0361,0040,0003,0125,0010,0001,0256,0000,0000,0340, 0377,0377,0377,0377,0377,0377,0377,0377,0377,0377,0377,0017,0277, 0253,0315,0257,0216,0377,0206,0146,0306,0371,0126,0232,0000,0004, - 0057,0012,0100,0360,0160,0360,0000,0040,0000,0017,0157,0000,0176, + 0057,0012,0100,0360,0160,0360,0000,0040,0000,0017,0157,0000,0176 }; Uchar xxh[26][13] = { @@ -122,5 +122,5 @@ Uchar xxh[26][13] = { 0040,0005,0020,0000,0040,0313,0231,0030,0000,0140,0000,0017,0056, 0140,0000,0160,0000,0200,0000,0000,0140,0000,0000,0000,0017,0240, 0065,0042,0060,0040,0000,0206,0231,0146,0006,0224,0220,0017,0004, - 0240,0000,0020,0000,0140,0000,0000,0220,0000,0000,0200,0017,0141, + 0240,0000,0020,0000,0140,0000,0000,0220,0000,0000,0200,0017,0141 }; diff --git a/src/cmd/troff/mkfile b/src/cmd/troff/mkfile index 17eb14af..f465e764 100644 --- a/src/cmd/troff/mkfile +++ b/src/cmd/troff/mkfile @@ -27,7 +27,7 @@ HFILES=tdef.h\ <$PLAN9/src/mkone -CFLAGS=-c -DUNICODE +CFLAGS=-DUNICODE TMACDIR='"tmac/tmac."' FONTDIR='"troff/font"' diff --git a/src/cmd/troff/n1.c b/src/cmd/troff/n1.c index 4c2bec4b..c65898ce 100644 --- a/src/cmd/troff/n1.c +++ b/src/cmd/troff/n1.c @@ -395,7 +395,7 @@ char gchtab[NCHARS] = { 000,000,000,000,000,000,001,000, /* f */ 000,000,000,000,000,000,000,000, 000,000,000,000,000,000,000,000, - 000,000,000,000,000,000,000,000, + 000,000,000,000,000,000,000,000 }; int realcbits(Tchar c) /* return character bits, or MOTCH if motion */ @@ -717,7 +717,7 @@ g0: if (ip) goto again; } -//g2: +/*g2: */ if (i >= 040) /* zapped: && i < 0177 */ goto g4; i = ifilt[i]; diff --git a/src/cmd/troff/n2.c b/src/cmd/troff/n2.c index 22fd1019..6495d330 100644 --- a/src/cmd/troff/n2.c +++ b/src/cmd/troff/n2.c @@ -4,6 +4,7 @@ * output, cleanup */ +#define _BSD_SOURCE 1 /* popen */ #include "tdef.h" #include "fns.h" #include "ext.h" diff --git a/src/cmd/troff/n7.c b/src/cmd/troff/n7.c index bcea354a..17ab2bd5 100644 --- a/src/cmd/troff/n7.c +++ b/src/cmd/troff/n7.c @@ -1,3 +1,4 @@ +#define _BSD_SOURCE 1 /* isascii */ #include "tdef.h" #include "fns.h" #include "ext.h" diff --git a/src/cmd/troff/ni.c b/src/cmd/troff/ni.c index a80cec64..ee09ed4a 100644 --- a/src/cmd/troff/ni.c +++ b/src/cmd/troff/ni.c @@ -22,7 +22,7 @@ Numtab numtab[NN] = { { PAIR('s', 't') }, { PAIR('s', 'b') }, { PAIR('c', '.') }, - { PAIR('$', '$') }, + { PAIR('$', '$') } }; @@ -150,7 +150,7 @@ Contab contab[NM] = { C(PAIR('s', 'y'), casesy), C(PAIR('l', 'f'), caself), C(PAIR('p', 't'), casept), - C(PAIR('g', 'd'), casegd), + C(PAIR('g', 'd'), casegd) }; @@ -228,7 +228,7 @@ Env env[NEV] = { { /* this sets up env[0] */ /* int pendnf */ 0, /* int spread */ 0, /* int it */ 0, /* input trap count */ -/* int itmac */ 0, +/* int itmac */ 0 } }; Env *envp = env; /* start off in env 0 */ diff --git a/src/cmd/troff/suftab.c b/src/cmd/troff/suftab.c index 1aa8a009..858a6419 100644 --- a/src/cmd/troff/suftab.c +++ b/src/cmd/troff/suftab.c @@ -608,5 +608,5 @@ Uchar *suftab[] = { 0, 0, sufy, - 0, + 0 }; |