--- ray/src/common/badarg.c 1991/11/07 11:03:34 1.1 +++ ray/src/common/badarg.c 2003/06/07 12:50:20 2.4 @@ -1,15 +1,19 @@ -/* Copyright (c) 1991 Regents of the University of California */ - #ifndef lint -static char SCCSid[] = "$SunId$ LBL"; +static const char RCSid[] = "$Id: badarg.c,v 2.4 2003/06/07 12:50:20 schorsch Exp $"; #endif - /* * Check argument list against format string. + * + * External symbols declared in standard.h */ -#define NULL 0 +#include "copyright.h" +#include + +#include "standard.h" + + int badarg(ac, av, fl) /* check argument list */ int ac; @@ -25,15 +29,15 @@ register char *fl; return(-1); switch (*fl) { case 's': /* string */ - if (**av == '\0' || **av == ' ' || **av == '\t') + if (**av == '\0' || isspace(**av)) return(i); break; case 'i': /* integer */ - if (!isintd(*av, " \t")) + if (!isintd(*av, " \t\r\n")) return(i); break; case 'f': /* float */ - if (!isfltd(*av, " \t")) + if (!isfltd(*av, " \t\r\n")) return(i); break; default: /* bad call! */