forked from OSchip/llvm-project
Revert 217719, that wasn't the right fix, that should complete user names, and
anyway /Vol doesn't complete correctly either. Somehow we're chopping the names up incorrectly before passing them into the completer. llvm-svn: 217720
This commit is contained in:
parent
2614db1a13
commit
2f21bbc804
|
@ -66,9 +66,9 @@ FileSpec::ResolveUsername (llvm::SmallVectorImpl<char> &path)
|
|||
|
||||
llvm::StringRef path_str(path.data());
|
||||
size_t slash_pos = path_str.find_first_of("/", 1);
|
||||
if (slash_pos == 1 || path_str.size() == 1)
|
||||
if (slash_pos == 1)
|
||||
{
|
||||
// A path of the form ~ or ~/ resolves to the current user's home dir
|
||||
// A path of ~/ resolves to the current user's home dir
|
||||
llvm::SmallString<64> home_dir;
|
||||
if (!llvm::sys::path::home_directory(home_dir))
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue