string.h revision 1539
11539Srgrimes/*-
21539Srgrimes * Copyright (c) 1990, 1993
31539Srgrimes *	The Regents of the University of California.  All rights reserved.
41539Srgrimes *
51539Srgrimes * Redistribution and use in source and binary forms, with or without
61539Srgrimes * modification, are permitted provided that the following conditions
71539Srgrimes * are met:
81539Srgrimes * 1. Redistributions of source code must retain the above copyright
91539Srgrimes *    notice, this list of conditions and the following disclaimer.
101539Srgrimes * 2. Redistributions in binary form must reproduce the above copyright
111539Srgrimes *    notice, this list of conditions and the following disclaimer in the
121539Srgrimes *    documentation and/or other materials provided with the distribution.
131539Srgrimes * 3. All advertising materials mentioning features or use of this software
141539Srgrimes *    must display the following acknowledgement:
151539Srgrimes *	This product includes software developed by the University of
161539Srgrimes *	California, Berkeley and its contributors.
171539Srgrimes * 4. Neither the name of the University nor the names of its contributors
181539Srgrimes *    may be used to endorse or promote products derived from this software
191539Srgrimes *    without specific prior written permission.
201539Srgrimes *
211539Srgrimes * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
221539Srgrimes * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
231539Srgrimes * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
241539Srgrimes * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
251539Srgrimes * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
261539Srgrimes * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
271539Srgrimes * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
281539Srgrimes * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
291539Srgrimes * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
301539Srgrimes * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
311539Srgrimes * SUCH DAMAGE.
321539Srgrimes *
331539Srgrimes *	@(#)string.h	8.1 (Berkeley) 6/2/93
341539Srgrimes */
351539Srgrimes
361539Srgrimes#ifndef _STRING_H_
371539Srgrimes#define	_STRING_H_
381539Srgrimes#include <machine/ansi.h>
391539Srgrimes
401539Srgrimes#ifdef	_BSD_SIZE_T_
411539Srgrimestypedef	_BSD_SIZE_T_	size_t;
421539Srgrimes#undef	_BSD_SIZE_T_
431539Srgrimes#endif
441539Srgrimes
451539Srgrimes#ifndef	NULL
461539Srgrimes#define	NULL	0
471539Srgrimes#endif
481539Srgrimes
491539Srgrimes#include <sys/cdefs.h>
501539Srgrimes
511539Srgrimes__BEGIN_DECLS
521539Srgrimesvoid	*memchr __P((const void *, int, size_t));
531539Srgrimesint	 memcmp __P((const void *, const void *, size_t));
541539Srgrimesvoid	*memcpy __P((void *, const void *, size_t));
551539Srgrimesvoid	*memmove __P((void *, const void *, size_t));
561539Srgrimesvoid	*memset __P((void *, int, size_t));
571539Srgrimeschar	*strcat __P((char *, const char *));
581539Srgrimeschar	*strchr __P((const char *, int));
591539Srgrimesint	 strcmp __P((const char *, const char *));
601539Srgrimesint	 strcoll __P((const char *, const char *));
611539Srgrimeschar	*strcpy __P((char *, const char *));
621539Srgrimessize_t	 strcspn __P((const char *, const char *));
631539Srgrimeschar	*strerror __P((int));
641539Srgrimessize_t	 strlen __P((const char *));
651539Srgrimeschar	*strncat __P((char *, const char *, size_t));
661539Srgrimesint	 strncmp __P((const char *, const char *, size_t));
671539Srgrimeschar	*strncpy __P((char *, const char *, size_t));
681539Srgrimeschar	*strpbrk __P((const char *, const char *));
691539Srgrimeschar	*strrchr __P((const char *, int));
701539Srgrimessize_t	 strspn __P((const char *, const char *));
711539Srgrimeschar	*strstr __P((const char *, const char *));
721539Srgrimeschar	*strtok __P((char *, const char *));
731539Srgrimessize_t	 strxfrm __P((char *, const char *, size_t));
741539Srgrimes
751539Srgrimes/* Nonstandard routines */
761539Srgrimes#ifndef _ANSI_SOURCE
771539Srgrimesint	 bcmp __P((const void *, const void *, size_t));
781539Srgrimesvoid	 bcopy __P((const void *, void *, size_t));
791539Srgrimesvoid	 bzero __P((void *, size_t));
801539Srgrimesint	 ffs __P((int));
811539Srgrimeschar	*index __P((const char *, int));
821539Srgrimesvoid	*memccpy __P((void *, const void *, int, size_t));
831539Srgrimeschar	*rindex __P((const char *, int));
841539Srgrimesint	 strcasecmp __P((const char *, const char *));
851539Srgrimeschar	*strdup __P((const char *));
861539Srgrimesvoid	 strmode __P((int, char *));
871539Srgrimesint	 strncasecmp __P((const char *, const char *, size_t));
881539Srgrimeschar	*strsep __P((char **, const char *));
891539Srgrimesvoid	 swab __P((const void *, void *, size_t));
901539Srgrimes#endif
911539Srgrimes__END_DECLS
921539Srgrimes
931539Srgrimes#endif /* _STRING_H_ */
94