coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 1/4] stat: adjustments to statx defines


From: Pádraig Brady
Subject: [PATCH 1/4] stat: adjustments to statx defines
Date: Mon, 3 Jun 2019 03:55:49 +0100

* src/stat.c: Adjust indenting to pass `make syntax-check`.
Also exclude more code on unsupported systems to avoid
compiler warnings.
---
 src/stat.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/stat.c b/src/stat.c
index 9e1ee09..1cb9552 100644
--- a/src/stat.c
+++ b/src/stat.c
@@ -201,6 +201,7 @@ enum cached_mode
   cached_always
 };
 
+#if HAVE_STATX && defined STATX_INO
 static char const *const cached_args[] =
 {
   "default", "never", "always", NULL
@@ -210,6 +211,7 @@ static enum cached_mode const cached_modes[] =
 {
   cached_default, cached_never, cached_always
 };
+#endif
 
 static struct option const long_options[] =
 {
@@ -1528,7 +1530,7 @@ get_birthtime (int fd, char const *filename, struct stat 
const *st)
 {
   struct timespec ts = get_stat_birthtime (st);
 
-#if HAVE_GETATTRAT
+# if HAVE_GETATTRAT
   if (ts.tv_nsec < 0)
     {
       nvlist_t *response;
@@ -1550,7 +1552,7 @@ get_birthtime (int fd, char const *filename, struct stat 
const *st)
           nvlist_free (response);
         }
     }
-#endif
+# endif
 
   return ts;
 }
-- 
2.9.3




reply via email to

[Prev in Thread] Current Thread [Next in Thread]