*** UNIX MANUAL PAGE BROWSER ***

A Nergahak database for man pages research.

Navigation

Directory Browser

1Browse 4.4BSD4.4BSD
1Browse Digital UNIXDigital UNIX 4.0e
1Browse FreeBSDFreeBSD 14.3
1Browse MINIXMINIX 3.4.0rc6-d5e4fc0
1Browse NetBSDNetBSD 10.1
1Browse OpenBSDOpenBSD 7.7
1Browse UNIX v7Version 7 UNIX
1Browse UNIX v10Version 10 UNIX

Manual Page Search

Manual Page Result

0 Command: strcspn | Section: 3 | Source: Digital UNIX | File: strcspn.3.gz
strspn(3) Library Functions Manual strspn(3) NAME strcspn, strspn - Returns length of initial segment of string LIBRARY Standard C Library (libc.so, libc.a) SYNOPSIS #include <string.h> size_t strcspn( const char *s1, const char *s2); size_t strspn( const char *s1, const char *s2); STANDARDS Interfaces documented on this reference page conform to industry stan- dards as follows: strcspn(), strspn(): XPG4, XPG4-UNIX Refer to the standards(5) reference page for more information about in- dustry standards and associated tags. PARAMETERS Points to a character string being checked for an initial segment. Points to a string containing a set of bytes that define the initial segment. DESCRIPTION The strspn() function computes the length of the maximum initial seg- ment of the string pointed to by the s1 parameter, which consists en- tirely of bytes from the string pointed to by the s2 parameter. The strcspn() function computes the byte length of the maximum initial segment of the string pointed to by the s1 parameter, which consists entirely of bytes that are not from the string pointed to by the s2 pa- rameter. The strspn() and strcspn() functions treat the s2 parameter as a series of bytes; these functions do not treat a multibyte character as a sin- gle unit but rather as a series of separate bytes. There are no equiva- lent functions for multibyte character strings. The wcsspn() and wcsc- spn() functions provide the same functionality for wide character strings. RETURN VALUES Upon successful completion, the strcspn(), and strspn() functions re- turn the length of the string segment. [Digital] On error, a value of -1 cast to size_t is returned. RELATED INFORMATION Functions: string(3), wcsspn(3)/wcscspn(3) Standards: standards(5) delim off strspn(3)

Navigation Options