How to deal with pointer to strings from DLL function calls results?


I'm trying to use an MQL library that has this in it and gets this from a DLL. I'm pretty sure the result is a pointer to a char *

My question is how can I receive this char * and use it in MQL? How can I convert it to a string?

I think intptr_t is a long or an int. I'm guessing a long because of 64 bit assuming MT5 is 64 bit. 

// Resolves system errors and 0MQ errors to human-readable string
intptr_t zmq_strerror(int errnum);