summaryrefslogtreecommitdiff
path: root/src/ln.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ln.c')
-rw-r--r--src/ln.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/ln.c b/src/ln.c
index 2afeb98ca..35a879033 100644
--- a/src/ln.c
+++ b/src/ln.c
@@ -227,8 +227,7 @@ do_link (const char *source, const char *dest)
misleading. */
&& (backup_type == none || !symbolic_link)
&& (!symbolic_link || stat (source, &source_stats) == 0)
- && source_stats.st_dev == dest_stats.st_dev
- && source_stats.st_ino == dest_stats.st_ino
+ && SAME_INODE (source_stats, dest_stats)
/* The following detects whether removing DEST will also remove
SOURCE. If the file has only one link then both are surely
the same link. Otherwise check whether they point to the same