Bell 32V development
[unix-history] / usr / src / cmd / refer / mkey2.c
index bda2005..94949b1 100644 (file)
@@ -1,7 +1,7 @@
 # include "stdio.h"
 # include "ctype.h"
 
 # include "stdio.h"
 # include "ctype.h"
 
-       static int eof 0;
+       static int eof 0;
        static long lp, lim;
        static int alph, used, prevc;
        static char *p, key[20];
        static long lp, lim;
        static int alph, used, prevc;
        static char *p, key[20];
@@ -68,8 +68,8 @@ long grec (s, f)
        FILE *f;
 {
        char tm[200];
        FILE *f;
 {
        char tm[200];
-       int curtype 0;
-       long len 0L, tlen 0L;
+       int curtype 0;
+       long len = 0L, tlen = 0L;
        extern int wholefile;
        if (eof) return(0);
        *s = 0;
        extern int wholefile;
        if (eof) return(0);
        *s = 0;
@@ -92,10 +92,11 @@ long grec (s, f)
        eof=1;
        return(s[0] ? len : 0L);
 }
        eof=1;
        return(s[0] ? len : 0L);
 }
+char *
 trimnl(ln)
        char *ln;
 {
 trimnl(ln)
        char *ln;
 {
-register char *p ln;
+register char *p ln;
 while (*p) p++;
 p--;
 if (*p == '\n') *p=0;
 while (*p) p++;
 p--;
 if (*p == '\n') *p=0;