(gobble_file): If not using long format, don't invoke acl; it's not needed.
authorJim Meyering <jim@meyering.net>
Sun, 31 Dec 2000 08:33:49 +0000 (08:33 +0000)
committerJim Meyering <jim@meyering.net>
Sun, 31 Dec 2000 08:33:49 +0000 (08:33 +0000)
src/ls.c

index 467625816638c6f074843057416751b37aadfa58..ed1783da7e6faf8a7707759db051b834c4bae87b 100644 (file)
--- a/src/ls.c
+++ b/src/ls.c
@@ -1899,9 +1899,10 @@ gobble_file (const char *name, enum filetype type, int explicit_arg,
        }
 
 #if USE_ACL
-      files[files_index].have_acl =
-       (! S_ISLNK (files[files_index].stat.st_mode)
-        && 4 < acl (path, GETACLCNT, 0, NULL));
+      if (format == long_format)
+       files[files_index].have_acl =
+         (! S_ISLNK (files[files_index].stat.st_mode)
+          && 4 < acl (path, GETACLCNT, 0, NULL));
 #endif
 
       if (S_ISLNK (files[files_index].stat.st_mode)