This function computes the prefix length of the string pointed to by dest which consists entirely of characters that are excluded from the string pointed to by src.
The scanning stops at the first null in dest or after dmax characters. The exclusion string is checked to the null or after slen characters.
- Parameters
-
[in] | dest | pointer to string to determine the prefix |
[in] | dmax | restricted maximum length of string dest |
[in] | src | pointer to exclusion string |
[in] | slen | restricted maximum length of string src |
[out] | count | pointer to a count variable that will be updated with the dest substring length |
- Precondition
- Neither dest nor src shall be a null pointer.
-
count shall not be a null pointer.
-
dmax shall not be 0
-
dmax shall not be greater than RSIZE_MAX_STR
- Return values
-
EOK | when operation is successful |
ESNULLP | when dest/src/count is NULL pointer |
ESZEROL | when dmax/slen = 0 |
ESLEMAX | when dmax/slen > RSIZE_MAX_STR |
- See also
- strspn_s(), strpbrk_s(), strstr_s()