summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorEric Blake <ebb9@byu.net>2009-09-04 15:40:22 -0600
committerEric Blake <ebb9@byu.net>2009-09-04 15:46:03 -0600
commit8a0efd04dc9583c96b4a0d3c311ff216e07dcdcd (patch)
tree5b4a346a6894663b5b2ad05d6f152ea216116942 /m4
parentee67d8ea6bd183f5ce32d90a6764705d766c3d6b (diff)
downloadgnulib-8a0efd04dc9583c96b4a0d3c311ff216e07dcdcd.tar.gz
link-follow: fix logic bug in prior patch
* m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Fix bug that reversed sense of yes and no in prior patch. Avoid confusing compilation failure with desired semantics. Signed-off-by: Eric Blake <ebb9@byu.net>
Diffstat (limited to 'm4')
-rw-r--r--m4/link-follow.m412
1 files changed, 6 insertions, 6 deletions
diff --git a/m4/link-follow.m4 b/m4/link-follow.m4
index eb98c3b62b..48885eae48 100644
--- a/m4/link-follow.m4
+++ b/m4/link-follow.m4
@@ -1,4 +1,4 @@
-# serial 13
+# serial 14
dnl Run a program to determine whether link(2) follows symlinks.
dnl Set LINK_FOLLOWS_SYMLINKS accordingly.
@@ -60,17 +60,17 @@ AC_DEFUN([gl_FUNC_LINK_FOLLOWS_SYMLINK],
/* If the dev/inode of hard and file are the same, then
the link call followed the symlink. */
- return SAME_INODE (sb_hard, sb_file) ? 0 : 1;
+ return SAME_INODE (sb_hard, sb_file) ? 1 : 0;
}
]])],
- [gl_cv_func_link_follows_symlink=yes],
- [gl_cv_func_link_follows_symlink=no],
+ [gl_cv_func_link_follows_symlink=no], dnl GNU behavior
+ [gl_cv_func_link_follows_symlink=yes], dnl Followed link/compile failed
[gl_cv_func_link_follows_symlink=unknown] dnl We're cross compiling.
)
])
case $gl_cv_func_link_follows_symlink in
- yes) ;;
- no) gl_link_follows_symlinks=1 ;;
+ yes) gl_link_follows_symlinks=1 ;;
+ no) ;; # already defaulted to 0
*) gl_link_follows_symlinks=-1 ;;
esac
fi