The common style is to use a pointer for output parameters. Please change to `std::string*` and check before using it in the function.