#include <isc/formatcheck.h>
#include <isc/int.h>
#include <isc/lang.h>
#include <isc/platform.h>
#include <isc/types.h>
#include <string.h>
Go to the source code of this file.
Defines | |
#define | ISC_STRING_H 1 |
#define | ISC_STRING_MAGIC 0x5e |
Functions | |
ISC_LANG_BEGINDECLS isc_uint64_t | isc_string_touint64 (char *source, char **endp, int base) |
Convert the string pointed to by 'source' to isc_uint64_t. | |
isc_result_t | isc_string_copy (char *target, size_t size, const char *source) |
void | isc_string_copy_truncate (char *target, size_t size, const char *source) |
isc_result_t | isc_string_append (char *target, size_t size, const char *source) |
void | isc_string_append_truncate (char *target, size_t size, const char *source) |
isc_result_t | isc_string_printf (char *target, size_t size, const char *format,...) ISC_FORMAT_PRINTF(3 |
isc_result_t void | isc_string_printf_truncate (char *target, size_t size, const char *format,...) ISC_FORMAT_PRINTF(3 |
isc_result_t void char * | isc_string_regiondup (isc_mem_t *mctx, const isc_region_t *source) |
char * | isc_string_separate (char **stringp, const char *delim) |
size_t | isc_string_strlcpy (char *dst, const char *src, size_t size) |
size_t | isc_string_strlcat (char *dst, const char *src, size_t size) |
char * | isc_string_strcasestr (const char *big, const char *little) |
Definition in file string.h.
#define ISC_STRING_MAGIC 0x5e |
Definition at line 37 of file string.h.
Referenced by isc_string_append(), isc_string_copy(), and isc_string_printf().
ISC_LANG_BEGINDECLS isc_uint64_t isc_string_touint64 | ( | char * | source, | |
char ** | endp, | |||
int | base | |||
) |
Convert the string pointed to by 'source' to isc_uint64_t.
On successful conversion 'endp' points to the first character after conversion is complete.
'base': 0 or 2..36
If base is 0 the base is computed from the string type.
On error 'endp' points to 'source'.
Definition at line 62 of file string.c.
Referenced by fromtext_any_tsig(), isc_netscope_pton(), and parse_unitstring().
isc_result_t isc_string_copy | ( | char * | target, | |
size_t | size, | |||
const char * | source | |||
) |
Definition at line 126 of file string.c.
References ENSURE, ISC_R_NOSPACE, ISC_R_SUCCESS, ISC_STRING_MAGIC, and REQUIRE.
void isc_string_copy_truncate | ( | char * | target, | |
size_t | size, | |||
const char * | source | |||
) |
isc_result_t isc_string_append | ( | char * | target, | |
size_t | size, | |||
const char * | source | |||
) |
Definition at line 149 of file string.c.
References ENSURE, ISC_R_NOSPACE, ISC_R_SUCCESS, ISC_STRING_MAGIC, and REQUIRE.
void isc_string_append_truncate | ( | char * | target, | |
size_t | size, | |||
const char * | source | |||
) |
isc_result_t isc_string_printf | ( | char * | target, | |
size_t | size, | |||
const char * | format, | |||
... | ||||
) |
Referenced by dns_journal_compact(), dns_journal_open(), reverse_from_address(), and stf_from_address().
isc_result_t void isc_string_printf_truncate | ( | char * | target, | |
size_t | size, | |||
const char * | format, | |||
... | ||||
) |
isc_result_t void char* isc_string_regiondup | ( | isc_mem_t * | mctx, | |
const isc_region_t * | source | |||
) |
Definition at line 210 of file string.c.
References isc_region::base, isc_mem_allocate, isc_region::length, and REQUIRE.
char* isc_string_separate | ( | char ** | stringp, | |
const char * | delim | |||
) |
size_t isc_string_strlcpy | ( | char * | dst, | |
const char * | src, | |||
size_t | size | |||
) |
size_t isc_string_strlcat | ( | char * | dst, | |
const char * | src, | |||
size_t | size | |||
) |
char* isc_string_strcasestr | ( | const char * | big, | |
const char * | little | |||
) |