From: Eric Blake Date: Wed, 14 Sep 2011 14:19:35 +0000 (-0600) Subject: opendir: avoid compile warning X-Git-Tag: v0.1~1910 X-Git-Url: http://erislabs.net/gitweb/?a=commitdiff_plain;h=6c9a77897ffc9323910cfdb25bf32dae44adbb53;p=gnulib.git opendir: avoid compile warning If HAVE_OPENDIR but also REPLACE_FCHDIR, then errno was used without including the proper header. * lib/opendir.c (includes): Always include errno.h. Reported by Tatsuro MATSUOKA. Signed-off-by: Eric Blake --- diff --git a/ChangeLog b/ChangeLog index bab5ba21a..52fe92daf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2011-09-14 Eric Blake + + opendir: avoid compile warning + * lib/opendir.c (includes): Always include errno.h. + Reported by Tatsuro MATSUOKA. + 2011-09-14 Jim Meyering maint.mk: sc_tight_scope: propagate failure from sub-make diff --git a/lib/opendir.c b/lib/opendir.c index cb7f67c10..06c611f2e 100644 --- a/lib/opendir.c +++ b/lib/opendir.c @@ -19,6 +19,8 @@ /* Specification. */ #include +#include + #if HAVE_OPENDIR /* Override opendir(), to keep track of the open file descriptors. @@ -26,7 +28,6 @@ #else -# include # include # include