Aspects


vs


Strcpy

A C standard library function: `strcpy` is used to copy non-overlapping, null-terminated strings

Strdup

The strdup() function duplicates a string

Others

Quality Example
Nicer

"In general it is nicer in c to have the caller allocate memory not the callee - hence why strcpy is a nicer function in my opinion than strdup"

from question "Where should I deallocate memory within functions?"

Back to Home
Data comes from Stack Exchange with CC-BY-SA-3.0