S
sposes
Im very much a newbie but perhaps somehone can help me. Ive been
searching for a way to convert a std::string to a unsigned char*
The situation is I have a function that wants a unsigned char* and I
want to give it a std::string
no matching function for call to `MD5::update(std::string&, size_t)'
candidates are: void MD5::update(unsigned char*, unsigned int)
void PrintMD5(string str){
MD5 context;
context.update(str, str.size());
context.finalize();
cout << "MD5: " << context << endl;
return;
}
I hope someone can help me solve this delema.
searching for a way to convert a std::string to a unsigned char*
The situation is I have a function that wants a unsigned char* and I
want to give it a std::string
no matching function for call to `MD5::update(std::string&, size_t)'
candidates are: void MD5::update(unsigned char*, unsigned int)
void PrintMD5(string str){
MD5 context;
context.update(str, str.size());
context.finalize();
cout << "MD5: " << context << endl;
return;
}
I hope someone can help me solve this delema.