You shouldn’t use strcpy() to copy a std::string, only use it for C-Style strings.
If you want to copy a to b then just use the = operator.
string a = "text";
string b = "image";
b = a;
You shouldn’t use strcpy() to copy a std::string, only use it for C-Style strings.
If you want to copy a to b then just use the = operator.
string a = "text";
string b = "image";
b = a;