diff options
Diffstat (limited to 'pkgs/build-support/kernel/make-initrd-ng/src/main.rs')
-rw-r--r-- | pkgs/build-support/kernel/make-initrd-ng/src/main.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pkgs/build-support/kernel/make-initrd-ng/src/main.rs b/pkgs/build-support/kernel/make-initrd-ng/src/main.rs index 53096a842329c..daa688976c6c8 100644 --- a/pkgs/build-support/kernel/make-initrd-ng/src/main.rs +++ b/pkgs/build-support/kernel/make-initrd-ng/src/main.rs @@ -195,7 +195,7 @@ fn handle_path( .wrap_err_with(|| format!("failed to resolve symlink of {:?}", source))?; // Create the link, then push its target to the queue - if !target.exists() { + if !target.exists() && !target.is_symlink() { unix::fs::symlink(&link_target, &target).wrap_err_with(|| { format!("failed to symlink {:?} to {:?}", link_target, target) })?; |