I have unsigned char*, want to convert it to std::string. Can you please tell me the safest way to do this?
unsigned char*
std::string
BYTE is nothing but typedef unsigned char BYTE;
typedef unsigned char BYTE;
You can easily use any of below constructors
string ( const char * s, size_t n ); string ( const char * s );