aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/postscript/tr2post/Bgetfield.c
diff options
context:
space:
mode:
authorwkj <devnull@localhost>2004-05-17 02:24:15 +0000
committerwkj <devnull@localhost>2004-05-17 02:24:15 +0000
commite8fb1d3efb114d1859f14fda2b6681d99df1f48a (patch)
treea3b437370521c9eff6cab00dd77fd2d95a3dc090 /src/cmd/postscript/tr2post/Bgetfield.c
parent8a3cbc157981485adc947c0477dc3e4907acc9a3 (diff)
downloadplan9port-e8fb1d3efb114d1859f14fda2b6681d99df1f48a.tar.gz
plan9port-e8fb1d3efb114d1859f14fda2b6681d99df1f48a.tar.bz2
plan9port-e8fb1d3efb114d1859f14fda2b6681d99df1f48a.zip
tr2post and aux/download; download is a shell script in $PLAN9/bin.
Diffstat (limited to 'src/cmd/postscript/tr2post/Bgetfield.c')
-rw-r--r--src/cmd/postscript/tr2post/Bgetfield.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/cmd/postscript/tr2post/Bgetfield.c b/src/cmd/postscript/tr2post/Bgetfield.c
index 974fce62..fc0dfc13 100644
--- a/src/cmd/postscript/tr2post/Bgetfield.c
+++ b/src/cmd/postscript/tr2post/Bgetfield.c
@@ -4,6 +4,9 @@
#include "../common/common.h"
#include "tr2post.h"
+#undef isspace
+#define isspace risspace
+
int
isspace(Rune r)
{
@@ -11,9 +14,8 @@ isspace(Rune r)
}
int
-Bskipws(Biobufhdr *bp) {
+Bskipws(Biobuf *bp) {
int r;
- char c[UTFmax];
int sindex = 0;
/* skip over initial white space */
@@ -54,7 +56,7 @@ asc2dig(char c, int base) {
*/
int
-Bgetfield(Biobufhdr *bp, int type, void *thing, int size) {
+Bgetfield(Biobuf *bp, int type, void *thing, int size) {
int r;
Rune R;
char c[UTFmax];
@@ -65,6 +67,8 @@ Bgetfield(Biobufhdr *bp, int type, void *thing, int size) {
int dig;
unsigned int u = 0;
+ r = 0;
+
/* skip over initial white space */
if (Bskipws(bp) < 0)
return(-1);