[Lldb-commits] [lldb] r375146 - [Reproducer] Surface error if setting the cwd fails

Pavel Labath via lldb-commits lldb-commits at lists.llvm.org
Fri Oct 18 04:13:22 PDT 2019


On 17/10/2019 19:58, Jonas Devlieghere via lldb-commits wrote:
> +      cwd->erase(std::remove_if(cwd->begin(), cwd->end(), std::iscntrl),
> +                 cwd->end());

What is this hacking around? I can imagine a .rtrim() would be needed to 
remove a trailing cr/lf (though it would still be better and probably 
easy to just make sure the crlf is not added to the file), but this 
seems way over the top.

Btw, control characters can appear in file/directory names on most posix 
systems.


More information about the lldb-commits mailing list