1
0
mirror of https://github.com/RPCS3/rpcs3.git synced 2024-11-22 02:32:36 +01:00

Minor fix for fmt::split with empty string

Doesn't affect existing code, I believe.
Return at least 1 empty string if is_skip_empty=false.
This commit is contained in:
Nekotekina 2021-03-06 19:26:41 +03:00
parent 87af905018
commit 7cd79714fa

View File

@ -455,6 +455,11 @@ std::vector<std::string> fmt::split(std::string_view source, std::initializer_li
result.emplace_back(std::string(piece));
}
if (result.empty() && !is_skip_empty)
{
result.emplace_back();
}
return result;
}