mirror of
https://github.com/cemu-project/vcpkg.git
synced 2025-02-23 11:07:10 +01:00
Merge pull request #1793 from atkawa7/patch-1
[vcpkg] an empty delimiter causes the split function to fail
This commit is contained in:
commit
4d7ae2fd9a
@ -137,6 +137,11 @@ namespace vcpkg::Strings
|
||||
{
|
||||
std::vector<std::string> output;
|
||||
|
||||
if(delimiter.empty()){
|
||||
output.push_back(s);
|
||||
return output;
|
||||
}
|
||||
|
||||
size_t i = 0;
|
||||
for (size_t pos = s.find(delimiter); pos != std::string::npos; pos = s.find(delimiter, pos))
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user