21 #define MIN(x, y) ((x) < (y) ? (x) : (y)) 24 #define MAX(x, y) ((x) > (y) ? (x) : (y)) 27 #define safe_strncpy strlcpy 28 #define strcasestr_local strcasestr 29 #define strdup_local strdup 31 #define CALLOC(x, y) calloc(x, y) 32 #define object_decrease_nrof_by_one(xyz) object_decrease_nrof(xyz, 1) 36 void safe_strcat(
char *dest,
const char *orig,
size_t *curlen,
size_t maxlen);
39 #ifndef HAVE_STRCASESTR 40 char *
strcasestr(
const char *s,
const char *find);
44 char *strdup(
const char *str);
49 size_t strlcpy(
char *dst,
const char *src,
size_t size);
54 char *tempnam(
const char *tmpdir,
const char *prefix);
void safe_strcat(char *dest, const char *orig, size_t *curlen, size_t maxlen)
Simple function we use below to keep adding to the same string but also make sure we don't overwrite ...
size_t strlcpy(char *dst, const char *src, size_t size)
Portable implementation of strlcpy(3).
const char * strcasestr(const char *s, const char *find)