From 7f2b4ba8d9f0279e13cd9b88d1ef4e9cf979586a Mon Sep 17 00:00:00 2001 From: Danny Robson Date: Sun, 6 Dec 2020 07:03:04 +1000 Subject: [PATCH] stat: protect acl and xattr from Windows --- tools/stat.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/tools/stat.cpp b/tools/stat.cpp index 7b7be87..2ddac94 100644 --- a/tools/stat.cpp +++ b/tools/stat.cpp @@ -1,25 +1,28 @@ #include -#include -#include "../acl.hpp" #include #include #include #include #include +#include #include #include #include -#include #include #include //----------------------------------------------------------------------------- +#if !defined(PLATFORM_WIN32) +#include + +#include "acl.hpp" + void do_xattr (char const *path) { std::cout << ", xattr: "; @@ -75,6 +78,11 @@ void do_acl (char const *path) std::cout << cruft::acl (path, ACL_TYPE_ACCESS) << '\n'; } +#else +void do_xattr (char const *) { } +void do_acl (char const *) { } +#endif + /////////////////////////////////////////////////////////////////////////////// int main (int argc, char **argv)