3909 "zfs send -D" does not work
[illumos-gate.git] / usr / src / common / util / string.h
blob052eeab4a432ee6430e8a3129ad78990e0e91a49
1 /*
2 * CDDL HEADER START
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
19 * CDDL HEADER END
23 * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
24 * Use is subject to license terms.
27 #ifndef _COMMON_UTIL_STRING_H
28 #define _COMMON_UTIL_STRING_H
30 #pragma ident "%Z%%M% %I% %E% SMI"
32 #include <sys/types.h>
34 #ifdef __cplusplus
35 extern "C" {
36 #endif
38 #if !defined(_KMDB) && (!defined(_BOOT) || defined(__sparc))
40 extern size_t vsnprintf(char *, size_t, const char *, va_list);
41 /*PRINTFLIKE1*/
42 extern size_t snprintf(char *, size_t, const char *, ...);
44 #if defined(_BOOT) && defined(__sparc)
46 /*PRINTFLIKE2*/
47 extern int sprintf(char *, const char *, ...);
48 extern int vsprintf(char *, const char *, va_list);
50 #endif /* _BOOT && __sparc */
51 #endif /* !_KMDB && (!_BOOT || __sparc) */
53 extern char *strcat(char *, const char *);
54 extern char *strchr(const char *, int);
55 extern int strcmp(const char *, const char *);
56 extern int strncmp(const char *, const char *, size_t);
57 extern int strcasecmp(const char *, const char *);
58 extern int strncasecmp(const char *, const char *, size_t);
59 extern char *strcpy(char *, const char *);
60 extern char *strncpy(char *, const char *, size_t);
61 extern char *strrchr(const char *, int c);
62 extern char *strstr(const char *, const char *);
63 extern char *strpbrk(const char *, const char *);
64 extern char *strncat(char *, const char *, size_t);
65 extern size_t strlcat(char *, const char *, size_t);
66 extern size_t strlcpy(char *, const char *, size_t);
67 extern size_t strspn(const char *, const char *);
68 extern size_t strnlen(const char *, size_t);
70 #if defined(_BOOT) || defined(_KMDB)
72 extern char *strtok(char *, const char *);
73 extern size_t strlen(const char *);
75 #endif /* _BOOT || _KMDB */
77 #ifdef _KERNEL
79 extern int strident_valid(const char *);
80 extern void strident_canon(char *, size_t);
82 #endif /* _KERNEL */
84 #ifdef __cplusplus
86 #endif
88 #endif /* _COMMON_UTIL_STRING_H */