xref: /csrg-svn/usr.bin/pascal/libpc/NIL.c (revision 9136)
11668Smckusick /* Copyright (c) 1979 Regents of the University of California */
21668Smckusick 
3*9136Smckusick static char sccsid[] = "@(#)NIL.c 1.3 11/12/82";
41668Smckusick 
51668Smckusick #include "h00vars.h"
61668Smckusick 
7*9136Smckusick char ENIL[] = "Pointer value out of legal range\n";
8*9136Smckusick 
91668Smckusick char *
101668Smckusick NIL(ptr)
111668Smckusick 	char	*ptr;		/* pointer to struct */
121668Smckusick {
131668Smckusick 	if (ptr > _maxptr || ptr < _minptr) {
14*9136Smckusick 		ERROR(ENIL, 0);
151668Smckusick 		return;
161668Smckusick 	}
171668Smckusick 	return ptr;
181668Smckusick }
19