From 7284e71c584d91c40ff4b6e19cd75aef8aae7010 Mon Sep 17 00:00:00 2001 From: lukem Date: Sat, 20 Sep 1997 14:28:16 +0000 Subject: - WARNSify - deprecate register - getopts returns -1 not EOF - last character returned by fgetln() isn't always \n - cleanup .Nm use --- quiz/rxp.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'quiz/rxp.c') diff --git a/quiz/rxp.c b/quiz/rxp.c index f835913e..19a31bf6 100644 --- a/quiz/rxp.c +++ b/quiz/rxp.c @@ -1,4 +1,4 @@ -/* $NetBSD: rxp.c,v 1.5 1995/04/22 10:17:00 cgd Exp $ */ +/* $NetBSD: rxp.c,v 1.6 1997/09/20 14:28:19 lukem Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -37,11 +37,12 @@ * SUCH DAMAGE. */ +#include #ifndef lint #if 0 static char sccsid[] = "@(#)rxp.c 8.1 (Berkeley) 5/31/93"; #else -static char rcsid[] = "$NetBSD: rxp.c,v 1.5 1995/04/22 10:17:00 cgd Exp $"; +__RCSID("$NetBSD: rxp.c,v 1.6 1997/09/20 14:28:19 lukem Exp $"); #endif #endif /* not lint */ @@ -90,14 +91,14 @@ static int rxp__match __P((char *, int, Rxp_t *, Rxp_t *, char *)); int rxp_compile(s) - register char * s; + char * s; { return (rxp__compile(s, TRUE)); } static int rxp__compile(s, first) - register char *s; + char *s; int first; { static Rxp_t *rp; @@ -195,7 +196,7 @@ rxp__compile(s, first) */ int rxp_match(s) - register char * s; + char * s; { return (rxp__match(s, TRUE, NULL, NULL, NULL)); } @@ -210,8 +211,8 @@ rxp__match(s, first, j_succ, j_fail, sp_fail) { static Rxp_t *rp; static char *sp; - register int ch; - Rxp_t *grp_end; + int ch; + Rxp_t *grp_end = NULL; int err; if (first) { -- cgit v1.2.3