diff options
author | imp <imp@FreeBSD.org> | 2002-02-18 05:15:19 +0000 |
---|---|---|
committer | imp <imp@FreeBSD.org> | 2002-02-18 05:15:19 +0000 |
commit | 24cd0a3c91f27cb3589ccd980187ccc8c7c51b6d (patch) | |
tree | 275284ba202a3acb4c5d5041be389eba1a666e3b /games/quiz/quiz.c | |
parent | d533053fe68906076e15c9a57531ef155a7d4283 (diff) | |
download | FreeBSD-src-24cd0a3c91f27cb3589ccd980187ccc8c7c51b6d.zip FreeBSD-src-24cd0a3c91f27cb3589ccd980187ccc8c7c51b6d.tar.gz |
Remove __P
Remove __STDC__ (which means we now use stdarg rather than vararg)
Remove register
Remove main prototype
Diffstat (limited to 'games/quiz/quiz.c')
-rw-r--r-- | games/quiz/quiz.c | 37 |
1 files changed, 11 insertions, 26 deletions
diff --git a/games/quiz/quiz.c b/games/quiz/quiz.c index 1c26272..5bffadc 100644 --- a/games/quiz/quiz.c +++ b/games/quiz/quiz.c @@ -53,6 +53,7 @@ static const char rcsid[] = #include <ctype.h> #include <errno.h> +#include <stdarg.h> #include <stdio.h> #include <stdlib.h> #include <string.h> @@ -66,16 +67,16 @@ static QE qlist; static int catone, cattwo, tflag; static u_int qsize; -char *appdstr __P((char *, char *, size_t)); -void downcase __P((char *)); -void err __P((const char *, ...)); -void get_cats __P((char *, char *)); -void get_file __P((char *)); -char *next_cat __P((char *)); -void quiz __P((void)); -void score __P((u_int, u_int, u_int)); -void show_index __P((void)); -void usage __P((void)); +char *appdstr(char *, char *, size_t); +void downcase(char *); +void err(const char *, ...); +void get_cats(char *, char *); +void get_file(char *); +char *next_cat(char *); +void quiz(void); +void score(u_int, u_int, u_int); +void show_index(void); +void usage(void); int main(argc, argv) @@ -369,27 +370,11 @@ usage() exit(1); } -#if __STDC__ -#include <stdarg.h> -#else -#include <varargs.h> -#endif - void -#if __STDC__ err(const char *fmt, ...) -#else -err(fmt, va_alist) - char *fmt; - va_dcl -#endif { va_list ap; -#if __STDC__ va_start(ap, fmt); -#else - va_start(ap); -#endif (void)fprintf(stderr, "quiz: "); (void)vfprintf(stderr, fmt, ap); va_end(ap); |