mirror of
https://github.com/textmate/textmate.git
synced 2026-01-21 04:38:13 -05:00
Remove non-UTF-8 from completion command output
Previously an entire line containing non-UTF-8 would be discarded, now we only remove the problematic bytes.
This commit is contained in:
@@ -105,7 +105,8 @@ namespace ng
|
||||
{
|
||||
for(auto line : text::tokenize(delegate->result.begin(), delegate->result.end(), '\n'))
|
||||
{
|
||||
if(!line.empty() && utf8::is_valid(line.begin(), line.end()))
|
||||
line.erase(utf8::remove_malformed(line.begin(), line.end()), line.end());
|
||||
if(!line.empty())
|
||||
commandResult.push_back(line);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user