openat: declare in POSIX headers
[gnulib.git] / lib / fstatat.c
index 8b62912..2bf547e 100644 (file)
@@ -1,6 +1,6 @@
 /* Work around an fstatat bug on Solaris 9.
 
-   Copyright (C) 2006 Free Software Foundation, Inc.
+   Copyright (C) 2006, 2009 Free Software Foundation, Inc.
 
    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
 
 #include <config.h>
 
-#define COMPILING_FSTATAT 1
-#include "openat.h"
+#include <sys/stat.h>
 
 #include <errno.h>
 #include <string.h>
 
+#undef fstatat
+
 /* fstatat should always follow symbolic links that end in /, but on
    Solaris 9 it doesn't if AT_SYMLINK_NOFOLLOW is specified.  This is
    the same problem that lstat.c addresses, so solve it in a similar