changeset 7463:e73dc8933779

* lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too, for NetBSD. Problem reported by Bruno Haible.
author Paul Eggert <eggert@cs.ucla.edu>
date Mon, 09 Oct 2006 19:33:54 +0000
parents fcfa86784f9e
children cd0777252284
files ChangeLog lib/filemode.h
diffstat 2 files changed, 7 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
+
+	* lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
+	for NetBSD.  Problem reported by Bruno Haible.
+
 2006-10-09  Jim Meyering  <jim@meyering.net>
 
 	* lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
--- a/lib/filemode.h
+++ b/lib/filemode.h
@@ -22,7 +22,8 @@
 # include <sys/stat.h>
 
 # if HAVE_DECL_STRMODE
-#  include <string.h>
+#  include <string.h> /* FreeBSD, OpenBSD */
+#  include <unistd.h> /* NetBSD */
 # else
 void strmode (mode_t mode, char *str);
 # endif