mirror of
https://github.com/MaskRay/ccls.git
synced 2024-11-25 17:11:59 +00:00
Fix IsSymLink on Linux (#147)
IsSymlink was giving faulty results when finding recursive files on Linux. I've updated the function to use the built-in POSIX macro for checking if a file is a symlink.
This commit is contained in:
parent
c0c3fc41a4
commit
4aa92466eb
@ -335,7 +335,7 @@ bool IsSymLink(const std::string& path) {
|
||||
struct stat buf;
|
||||
int result;
|
||||
result = lstat(path.c_str(), &buf);
|
||||
return result == 0;
|
||||
return S_ISLNK(buf.st_mode);
|
||||
}
|
||||
|
||||
std::vector<std::string> GetPlatformClangArguments() {
|
||||
|
Loading…
Reference in New Issue
Block a user