Tweak error message
This commit is contained in:
parent
2b0365753a
commit
acb71aa5c6
|
@ -584,9 +584,9 @@ Path resolveExprPath(Path path)
|
|||
while (true) {
|
||||
// Basic cycle/depth limit to avoid infinite loops.
|
||||
if (++followCount >= maxFollow)
|
||||
throw Error(format("can't resolve expression. infinite symlink recursion in path '%1%'") % path);
|
||||
throw Error("too many symbolic links encountered while traversing the path '%s'", path);
|
||||
if (lstat(path.c_str(), &st))
|
||||
throw SysError(format("getting status of '%1%'") % path);
|
||||
throw SysError("getting status of '%s'", path);
|
||||
if (!S_ISLNK(st.st_mode)) break;
|
||||
path = absPath(readLink(path), dirOf(path));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue