11#ifndef _RTE_STRING_FNS_H_
12#define _RTE_STRING_FNS_H_
51 char **tokens,
int maxtokens,
char delim);
59rte_strlcpy(
char *dst,
const char *src,
size_t size)
61 return (
size_t)snprintf(dst, size,
"%s", src);
70rte_strlcat(
char *dst,
const char *src,
size_t size)
72 size_t l = strnlen(dst, size);
74 return l + rte_strlcpy(&dst[l], src, size - l);
75 return l + strlen(src);
79#ifdef RTE_EXEC_ENV_FREEBSD
81#define strlcpy(dst, src, size) rte_strlcpy(dst, src, size)
82#define strlcat(dst, src, size) rte_strlcat(dst, src, size)
87#include <bsd/string.h>
90#define strlcpy(dst, src, size) rte_strlcpy(dst, src, size)
91#define strlcat(dst, src, size) rte_strlcat(dst, src, size)
ssize_t rte_strscpy(char *dst, const char *src, size_t dsize)
int rte_strsplit(char *string, int stringlen, char **tokens, int maxtokens, char delim)