cstring · Section 3
cstr_copy
NAME
cstr_copy - create an independent copy of a string
LIBRARY
C Collections (libccollections, -lccollections)
SYNOPSIS
#include <ccollections/cstring.h> cstr_copy(s, err);
DESCRIPTION
This macro forwards its arguments to cstring_copy(), which allocates a new cstring with the same content as s.
PARAMETERS
s cstr to copy err Optional pointer to receive an error string on failure
RETURN VALUE
New cstr on success, NULL on failure
NOTES
You must destroy the cstring that this macro returns