1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-25 06:31:14 +02:00

Merge pull request #13120 from Mic92/fix-quoting

replaceSymlink: fix quoting in error message
This commit is contained in:
Jörg Thalheim 2025-05-01 10:25:22 +02:00 committed by GitHub
commit d5cefa625c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -629,14 +629,14 @@ void replaceSymlink(const fs::path & target, const fs::path & link)
fs::create_symlink(target, tmp);
} catch (fs::filesystem_error & e) {
if (e.code() == std::errc::file_exists) continue;
throw SysError("creating symlink '%1%' -> '%2%'", tmp, target);
throw SysError("creating symlink %1% -> %2%", tmp, target);
}
try {
fs::rename(tmp, link);
} catch (fs::filesystem_error & e) {
if (e.code() == std::errc::file_exists) continue;
throw SysError("renaming '%1%' to '%2%'", tmp, link);
throw SysError("renaming %1% to %2%", tmp, link);
}