[vlc-commits] posix: drop lstat() test

Rémi Denis-Courmont git at videolan.org
Mon Feb 12 18:45:52 CET 2018


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Mon Feb 12 19:41:14 2018 +0200| [055268706e64d369d9d0f2b38e0fd62e47b5c8c7] | committer: Rémi Denis-Courmont

posix: drop lstat() test

POSIX has required this since forever. Non-POSIX OS have their own
back-end already. (Incidentally, vlc_stat() is dead code.)

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=055268706e64d369d9d0f2b38e0fd62e47b5c8c7
---

 configure.ac           | 2 +-
 src/posix/filesystem.c | 3 ---
 2 files changed, 1 insertion(+), 4 deletions(-)

diff --git a/configure.ac b/configure.ac
index ae1a56e2eb..0c1b6beadc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -590,7 +590,7 @@ dnl Check for system libs needed
 need_libc=false
 
 dnl Check for usual libc functions
-AC_CHECK_FUNCS([accept4 daemon fcntl flock fstatvfs fork getenv getpwuid_r isatty lstat memalign mkostemp mmap open_memstream openat pipe2 pread posix_fadvise posix_madvise posix_memalign setlocale stricmp strnicmp strptime tdestroy uselocale])
+AC_CHECK_FUNCS([accept4 daemon fcntl flock fstatvfs fork getenv getpwuid_r isatty memalign mkostemp mmap open_memstream openat pipe2 pread posix_fadvise posix_madvise posix_memalign setlocale stricmp strnicmp strptime tdestroy uselocale])
 AC_REPLACE_FUNCS([aligned_alloc atof atoll dirfd fdopendir ffsll flockfile fsync getdelim getpid lldiv memrchr nrand48 poll recvmsg rewind sendmsg setenv strcasecmp strcasestr strdup strlcpy strndup strnlen strnstr strsep strtof strtok_r strtoll swab tfind timegm timespec_get strverscmp pathconf])
 AC_REPLACE_FUNCS([gettimeofday])
 AC_CHECK_FUNC(fdatasync,,
diff --git a/src/posix/filesystem.c b/src/posix/filesystem.c
index 6d3e8964c6..f21a646dca 100644
--- a/src/posix/filesystem.c
+++ b/src/posix/filesystem.c
@@ -37,9 +37,6 @@
 #include <unistd.h>
 #include <fcntl.h>
 #include <sys/stat.h>
-#ifndef HAVE_LSTAT
-# define lstat(a, b) stat(a, b)
-#endif
 #include <dirent.h>
 #include <sys/socket.h>
 



More information about the vlc-commits mailing list