运行程序时提示错误:
terminate called after throwing an instance of ‘std::logic_error’ what(): basic_string::_S_construct null not valid
string构造不能传入空指针xxx,即在xxx为空时会报上面错误,保证func返回不为空即可。
运行程序时提示错误:
terminate called after throwing an instance of ‘std::logic_error’ what(): basic_string::_S_construct null not valid
string构造不能传入空指针xxx,即在xxx为空时会报上面错误,保证func返回不为空即可。