I moved my code to use std::vector instead of char *mem = malloc(...) but now I am facing a problem that I can only access the vector d
std::vector
char *mem = malloc(...)
The standard way to access the vector data is to use
&data[0]