summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2003-02-19 07:32:37 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2003-02-19 07:32:37 +0000
commitce7671764357217480ac409c63773cf5581365a8 (patch)
tree43470b08fe4920c371814e388db82ca2e63ce503
parent2bf29363ec4ca7faeecb66c48e7d796c23a88ea1 (diff)
make this work on sparc64, some borrowed from netbsd; raj@cerias.purdue.edu
-rw-r--r--usr.bin/vgrind/RETEST/retest.c12
-rw-r--r--usr.bin/vgrind/extern.h6
-rw-r--r--usr.bin/vgrind/regexp.c42
-rw-r--r--usr.bin/vgrind/vfontedpr.c16
-rw-r--r--usr.bin/vgrind/vgrindefs.c6
5 files changed, 41 insertions, 41 deletions
diff --git a/usr.bin/vgrind/RETEST/retest.c b/usr.bin/vgrind/RETEST/retest.c
index 3c8e97e2878..db06101ad47 100644
--- a/usr.bin/vgrind/RETEST/retest.c
+++ b/usr.bin/vgrind/RETEST/retest.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: retest.c,v 1.3 2002/02/24 01:24:24 pvalchev Exp $ */
+/* $OpenBSD: retest.c,v 1.4 2003/02/19 07:32:36 deraadt Exp $ */
/* $NetBSD: retest.c,v 1.2 1994/11/17 08:28:18 jtc Exp $ */
/*
@@ -44,14 +44,14 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)retest.c 8.1 (Berkeley) 6/6/93";
#endif
-static char rcsid[] = "$OpenBSD: retest.c,v 1.3 2002/02/24 01:24:24 pvalchev Exp $":
+static char rcsid[] = "$OpenBSD: retest.c,v 1.4 2003/02/19 07:32:36 deraadt Exp $";
#endif /* not lint */
#include <ctype.h>
int l_onecase = 0;
-char * _start;
-char * _escaped;
+char * x_start;
+char * x_escaped;
char * convexp();
char * expmatch();
main()
@@ -98,8 +98,8 @@ main()
if (str[0] == '#')
break;
matstr[0] = 0;
- _start = str;
- _escaped = 0;
+ x_start = str;
+ x_escaped = 0;
match = expmatch (str, ireg, matstr);
if (match == 0)
printf ("FAILED\n");
diff --git a/usr.bin/vgrind/extern.h b/usr.bin/vgrind/extern.h
index a0823eb799c..02f589a62f3 100644
--- a/usr.bin/vgrind/extern.h
+++ b/usr.bin/vgrind/extern.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: extern.h,v 1.3 2002/02/16 21:27:56 millert Exp $ */
+/* $OpenBSD: extern.h,v 1.4 2003/02/19 07:32:36 deraadt Exp $ */
/* $NetBSD: extern.h,v 1.2 1994/11/17 08:27:59 jtc Exp $ */
/*
@@ -39,8 +39,8 @@
typedef int boolean;
-extern boolean _escaped; /* if last character was an escape */
-extern char *_start; /* start of the current string */
+extern boolean x_escaped; /* if last character was an escape */
+extern char *x_start; /* start of the current string */
extern char *l_acmbeg; /* string introducing a comment */
extern char *l_acmend; /* string ending a comment */
extern char *l_blkbeg; /* string begining of a block */
diff --git a/usr.bin/vgrind/regexp.c b/usr.bin/vgrind/regexp.c
index b88d1688eca..757451bce96 100644
--- a/usr.bin/vgrind/regexp.c
+++ b/usr.bin/vgrind/regexp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: regexp.c,v 1.4 2002/02/16 21:27:56 millert Exp $ */
+/* $OpenBSD: regexp.c,v 1.5 2003/02/19 07:32:36 deraadt Exp $ */
/* $NetBSD: regexp.c,v 1.3 1994/11/17 08:28:02 jtc Exp $ */
/*
@@ -45,7 +45,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)regexp.c 8.1 (Berkeley) 6/6/93";
#endif
-static char rcsid[] = "$OpenBSD: regexp.c,v 1.4 2002/02/16 21:27:56 millert Exp $";
+static char rcsid[] = "$OpenBSD: regexp.c,v 1.5 2003/02/19 07:32:36 deraadt Exp $";
#endif /* not lint */
#include <ctype.h>
@@ -59,8 +59,8 @@ static char rcsid[] = "$OpenBSD: regexp.c,v 1.4 2002/02/16 21:27:56 millert Exp
static void expconv(void);
-boolean _escaped; /* true if we are currently _escaped */
-char *_start; /* start of string */
+boolean x_escaped; /* true if we are currently x_escaped */
+char *x_start; /* start of string */
boolean l_onecase; /* true if upper and lower equivalent */
#define makelower(c) (isupper((c)) ? tolower((c)) : (c))
@@ -101,14 +101,14 @@ STRNCMP(s1, s2, len)
* internal format.
*
* Either meta symbols (\a \d or \p) or character strings or
- * operations ( alternation or perenthesizing ) can be
+ * operations ( alternation or parenthesizing ) can be
* specified. Each starts with a descriptor byte. The descriptor
* byte has STR set for strings, META set for meta symbols
* and OPER set for operations.
* The descriptor byte can also have the OPT bit set if the object
* defined is optional. Also ALT can be set to indicate an alternation.
*
- * For metasymbols the byte following the descriptor byte identities
+ * For metasymbols the byte following the descriptor byte identifies
* the meta symbol (containing an ascii 'a', 'd', 'p', '|', or '('). For
* strings the byte after the descriptor is a character count for
* the string:
@@ -183,7 +183,7 @@ expconv()
{
char *cs; /* pointer to current symbol in converted exp */
char c; /* character being processed */
- char *acs; /* pinter to last alternate */
+ char *acs; /* pointer to last alternate */
int temp;
/* let the conversion begin */
@@ -269,7 +269,7 @@ expconv()
OCNT(cs) = ccre - cs; /* offset to next symbol */
break;
- /* reurn from a recursion */
+ /* return from a recursion */
case ')':
if (acs != NIL) {
do {
@@ -301,7 +301,7 @@ expconv()
acs = cs; /* remember that the pointer is to be filles */
break;
- /* if its not a metasymbol just build a scharacter string */
+ /* if its not a metasymbol just build a character string */
default:
if (cs == NIL || (*cs & STR) == 0) {
cs = ccre;
@@ -324,11 +324,11 @@ expconv()
}
return;
}
-/* end of convertre */
+/* end of converter */
/*
- * The following routine recognises an irregular expresion
+ * The following routine recognises an irregular expression
* with the following special characters:
*
* \? - means last match was optional
@@ -457,7 +457,7 @@ expmatch (s, re, mstring)
return (ptr);
} else if (ptr != NIL && (*cs & OPT)) {
- /* it was aoptional so no match is ok */
+ /* it was optional so no match is ok */
return (ptr);
} else if (ptr != NIL) {
@@ -467,9 +467,9 @@ expmatch (s, re, mstring)
if (!isalnum(*s1) && *s1 != '_')
return (NIL);
if (*s1 == '\\')
- _escaped = _escaped ? FALSE : TRUE;
+ x_escaped = x_escaped ? FALSE : TRUE;
else
- _escaped = FALSE;
+ x_escaped = FALSE;
} while (*s1++);
return (NIL);
@@ -489,7 +489,7 @@ expmatch (s, re, mstring)
return (ptr);
} else if (ptr != NIL && (*cs & OPT)) {
- /* it was aoptional so no match is ok */
+ /* it was optional so no match is ok */
return (ptr);
} else if (ptr != NIL) {
@@ -497,15 +497,15 @@ expmatch (s, re, mstring)
return (NIL);
}
if (*s1 == '\\')
- _escaped = _escaped ? FALSE : TRUE;
+ x_escaped = x_escaped ? FALSE : TRUE;
else
- _escaped = FALSE;
+ x_escaped = FALSE;
} while (*s1++);
return (NIL);
- /* fail if we are currently _escaped */
+ /* fail if we are currently x_escaped */
case 'e':
- if (_escaped)
+ if (x_escaped)
return(NIL);
cs = MNEXT(cs);
break;
@@ -515,7 +515,7 @@ expmatch (s, re, mstring)
ptr = s;
while (*s == ' ' || *s == '\t')
s++;
- if (s != ptr || s == _start) {
+ if (s != ptr || s == x_start) {
/* match, be happy */
matched = 1;
@@ -567,7 +567,7 @@ expmatch (s, re, mstring)
/* check for start of line */
case '^':
- if (s == _start) {
+ if (s == x_start) {
/* match, be happy */
matched = 1;
diff --git a/usr.bin/vgrind/vfontedpr.c b/usr.bin/vgrind/vfontedpr.c
index e1e97a5ef8f..96d8eeb40bf 100644
--- a/usr.bin/vgrind/vfontedpr.c
+++ b/usr.bin/vgrind/vfontedpr.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: vfontedpr.c,v 1.6 2002/02/16 21:27:56 millert Exp $ */
-/* $NetBSD: vfontedpr.c,v 1.4 1996/03/21 18:08:30 jtc Exp $ */
+/* $OpenBSD: vfontedpr.c,v 1.7 2003/02/19 07:32:36 deraadt Exp $ */
+/* $NetBSD: vfontedpr.c,v 1.7 1998/12/19 23:41:53 christos Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)vfontedpr.c 8.1 (Berkeley) 6/6/93";
#endif
-static char rcsid[] = "$OpenBSD: vfontedpr.c,v 1.6 2002/02/16 21:27:56 millert Exp $";
+static char rcsid[] = "$OpenBSD: vfontedpr.c,v 1.7 2003/02/19 07:32:36 deraadt Exp $";
#endif /* not lint */
#include <sys/types.h>
@@ -289,7 +289,7 @@ main(argc, argv)
incomm = FALSE;
instr = FALSE;
inchr = FALSE;
- _escaped = FALSE;
+ x_escaped = FALSE;
blklevel = 0;
for (psptr=0; psptr<PSMAX; psptr++) {
pstack[psptr][0] = NULL;
@@ -365,8 +365,8 @@ putScp(os)
char *blksptr; /* end of a lexical block start */
char *blkeptr; /* end of a lexical block end */
- _start = os; /* remember the start for expmatch */
- _escaped = FALSE;
+ x_start = os; /* remember the start for expmatch */
+ x_escaped = FALSE;
if (nokeyw || incomm || instr)
goto skip;
if (isproc(s)) {
@@ -559,14 +559,14 @@ putKcp (start, end, force)
if (*start == '\t') {
while (*start == '\t')
start++;
- i = tabs(_start, start) - margin / 8;
+ i = tabs(x_start, start) - margin / 8;
printf("\\h'|%dn'", i * 10 + 1 - margin % 8);
continue;
}
if (!nokeyw && !force)
if ((*start == '#' || isidchr(*start))
- && (start == _start || !isidchr(start[-1]))) {
+ && (start == x_start || !isidchr(start[-1]))) {
i = iskw(start);
if (i > 0) {
ps("\\*(+K");
diff --git a/usr.bin/vgrind/vgrindefs.c b/usr.bin/vgrind/vgrindefs.c
index 9d5b3d65645..a4a559b45ab 100644
--- a/usr.bin/vgrind/vgrindefs.c
+++ b/usr.bin/vgrind/vgrindefs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vgrindefs.c,v 1.3 2001/11/19 19:02:17 mpech Exp $ */
+/* $OpenBSD: vgrindefs.c,v 1.4 2003/02/19 07:32:36 deraadt Exp $ */
/* $NetBSD: vgrindefs.c,v 1.5 1994/12/20 12:05:29 cgd Exp $ */
/*
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)vgrindefs.c 8.1 (Berkeley) 6/6/93";
#endif
-static char rcsid[] = "$OpenBSD: vgrindefs.c,v 1.3 2001/11/19 19:02:17 mpech Exp $";
+static char rcsid[] = "$OpenBSD: vgrindefs.c,v 1.4 2003/02/19 07:32:36 deraadt Exp $";
#endif /* not lint */
#define BUFSIZ 1024
@@ -308,7 +308,7 @@ tgetstr(id, area)
}
/*
- * Tdecode does the grung work to decode the
+ * Tdecode does the grunt work to decode the
* string capability escapes.
*/
static char *