safec
2.1
Safe C Library - ISO TR24731 Bounds Checking Interface
|
#include "safeclib_private.h"
#include "safe_str_constraint.h"
#include "safe_str_lib.h"
Go to the source code of this file.
Functions | |
errno_t | strcspn_s (const char *dest, rsize_t dmax, const char *src, rsize_t slen, rsize_t *count) |
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. More... | |
errno_t strcspn_s | ( | const char * | dest, |
rsize_t | dmax, | ||
const char * | src, | ||
rsize_t | slen, | ||
rsize_t * | count | ||
) |
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.
[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 |
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 |
Definition at line 73 of file strcspn_s.c.