fix: memory prematurely discarded when returning std::string rval; now have more mem leaks