# return true if both names are for the same file sub check_same_file_under_posix { my ($file_a, $file_b) = @_; my ($dev_a, $ino_a, @other_a) = stat($file_a); my ($dev_b, $ino_b, @other_b) = stat($file_b); if (($dev_a == $dev_b) && ($ino_a == $ino_b)) { return 1 } else { return 0 } }