Matthew Woehlke in
<http://lists.gnu.org/archive/html/bug-gzip/2006-11/msg00013.html>.
* bootstrap.conf (gnulib_modules): Remove openat, as it pulls in
fchdir.
* configure.ac: Check for fdopendir.
* gzip.c: Don't include openat.h; no longer needed.
(treat_dir) [!HAVE_FDOPENDIR]: Fall back on the old opendir method
since fdopendir is not available.
+2006-12-05 Paul Eggert <eggert@cs.ucla.edu>
+
+ Port to Tandem NSK/OSS, which lacks fchdir. Problem reported by
+ Matthew Woehlke in
+ <http://lists.gnu.org/archive/html/bug-gzip/2006-11/msg00013.html>.
+ * bootstrap.conf (gnulib_modules): Remove openat, as it pulls in
+ fchdir.
+ * configure.ac: Check for fdopendir.
+ * gzip.c: Don't include openat.h; no longer needed.
+ (treat_dir) [!HAVE_FDOPENDIR]: Fall back on the old opendir method
+ since fdopendir is not available.
+
2006-12-04 Paul Eggert <eggert@cs.ucla.edu>
* NEWS: Describe the following change briefly.
# gnulib modules used by this package.
gnulib_modules='
- openat
fcntl
fcntl-safer
fdl
AC_C_CONST
AC_HEADER_STDC
AC_CHECK_HEADERS_ONCE(fcntl.h limits.h memory.h time.h)
-AC_CHECK_FUNCS_ONCE([fchmod fchown lstat])
+AC_CHECK_FUNCS_ONCE([fchmod fchown fdopendir lstat])
AC_HEADER_DIRENT
AC_TYPE_SIGNAL
AC_TYPE_SIZE_T
#include "fcntl-safer.h"
#include "getopt.h"
-#include "openat.h"
#include "stat-time.h"
/* configuration */
char nbuf[MAX_PATH_LEN];
int len;
+#if HAVE_FDOPENDIR
dirp = fdopendir (fd);
+#else
+ close (fd);
+ dirp = opendir(dir);
+#endif
if (dirp == NULL) {
progerror(dir);
+#if HAVE_FDOPENDIR
close (fd);
+#endif
return ;
}
/*