STRDUP(3)

NAME
strdup - duplicate nul-terminated string

SYNOPSIS

DESCRIPTION
strdup copies the nul-terminated string s to a new location provided by malloc(3) and returns a pointer to the new copy. 0 is returned if malloc(3) failed.

SEE ALSO
malloc(3), memdup(3)