Hi.
Assuming I have a code snippet like below:
#include <iostream>
using namespace std;
char Mac[6] = { 0x0, 0x1, 0x2, 0x3, 0x4, 0x5 };
std::string csMac;
1. Whats the best way to do a deep copy from the c-style char array to
the c++ string object.
I know the other way around to assign to the string object (to use a
c_str() on the string).
Thanks
Ramesh
Assuming I have a code snippet like below:
#include <iostream>
using namespace std;
char Mac[6] = { 0x0, 0x1, 0x2, 0x3, 0x4, 0x5 };
std::string csMac;
1. Whats the best way to do a deep copy from the c-style char array to
the c++ string object.
I know the other way around to assign to the string object (to use a
c_str() on the string).
Thanks
Ramesh
Comment