bad char* to string conversion