diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2017-08-31 14:34:25 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2017-08-31 15:08:44 -0700 |
commit | fd1daf4e1824bb46c08ba6244b4d41c8cecb3642 (patch) | |
tree | 0b4f19a24b3413edb1e1e9788f10804458549003 /lib/glob.in.h | |
parent | c8e57c1ad7dabfd422a14015e1c81889eaf9d028 (diff) | |
download | gnulib-fd1daf4e1824bb46c08ba6244b4d41c8cecb3642.tar.gz |
glob: match dangling symlinks
This fixes a bug I inadvertently introduced to Gnulib when I
merged glibc glob back into gnulib on 2007-10-16. This fix is
inspired by a patch proposed for glibc by Adhemerval Zanella in:
https://sourceware.org/ml/libc-alpha/2017-08/msg00446.html
* doc/posix-functions/glob.texi: Update list of affected platforms.
* lib/glob.c (__lstat64): New macro.
(is_dir): New function.
(glob, glob_in_dir): Match symlinks even if they are dangling.
(link_stat, link_exists_p): Remove. All uses removed.
* lib/glob.in.h (__attribute_noinline__): Remove; no longer used.
* m4/glob.m4 (gl_PREREQ_GLOB): Do not check for fstatat.
* modules/glob (Depends-on): Remove dirfd.
* modules/glob-tests (Depends-on): Add symlink.
* tests/test-glob.c: Include errno.h, unistd.h.
(BASE): New macro.
(main): Test dangling symlinks, if symlinks are supported.
Diffstat (limited to 'lib/glob.in.h')
-rw-r--r-- | lib/glob.in.h | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/lib/glob.in.h b/lib/glob.in.h index cfb7e49969..b0d27cff6d 100644 --- a/lib/glob.in.h +++ b/lib/glob.in.h @@ -49,14 +49,6 @@ #define attribute_hidden -#ifndef __attribute_noinline__ -# if 3 < __GNUC__ + (1 <= __GNUC_MINOR__) -# define __attribute_noinline__ __attribute__ ((__noinline__)) -#else -# define __attribute_noinline__ /* Ignore */ -# endif -#endif - #if __GNUC__ < 3 # define __glibc_unlikely(cond) (cond) #else |