1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-04 03:01:47 +02:00

Improve symlink handling

This commit is contained in:
Eelco Dolstra 2022-05-17 13:56:26 +02:00
parent 2a53574675
commit df2aa29690
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE
7 changed files with 51 additions and 22 deletions

View file

@ -680,7 +680,7 @@ SourcePath resolveExprPath(const SourcePath & path)
{
/* If `path' is a symlink, follow it. This is so that relative
path references work. */
SourcePath path2 { path.accessor, path.path.resolveSymlinks() };
auto path2 = path.resolveSymlinks();
/* If `path' refers to a directory, append `/default.nix'. */
if (path2.lstat().type == InputAccessor::tDirectory)