std::string.find_last_of() wants a string not a character as argument
This commit is contained in:
@ -549,9 +549,9 @@ bool utils::is_double(const std::string & str) {
|
|||||||
|
|
||||||
std::string utils::path_basename(const std::string & path) {
|
std::string utils::path_basename(const std::string & path) {
|
||||||
#if defined(_WIN32)
|
#if defined(_WIN32)
|
||||||
size_t start = path.find_last_of('/\\');
|
size_t start = path.find_last_of("/\\");
|
||||||
#else
|
#else
|
||||||
size_t start = path.find_last_of('/');
|
size_t start = path.find_last_of("/");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (start == std::string::npos) {
|
if (start == std::string::npos) {
|
||||||
|
|||||||
Reference in New Issue
Block a user