]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
(decode_switches): Use getenv (POSIXLY_CORRECT), not undefined posix_pedantic.
authorJim Meyering <jim@meyering.net>
Sun, 21 Apr 1996 04:11:43 +0000 (04:11 +0000)
committerJim Meyering <jim@meyering.net>
Sun, 21 Apr 1996 04:11:43 +0000 (04:11 +0000)
src/ls.c

index 8b524d95496662ab809c4dc17fa09fd51ab16c17..5f56e857e309b70f6d0e3572f2477d65b3ff08ca 100644 (file)
--- a/src/ls.c
+++ b/src/ls.c
@@ -727,8 +727,10 @@ decode_switches (int argc, char **argv)
   }
 #endif
 
+  /* TABSIZE is not POSIX-approved.
+     Ignore it when POSIXLY_CORRECT is set.  */
   tabsize = 8;
-  if (!posix_pedantic && (p = getenv ("TABSIZE")))
+  if (getenv ("POSIXLY_CORRECT") == 0 && (p = getenv ("TABSIZE")))
     {
       if (xstrtol (p, NULL, 0, &tmp_long, NULL) == LONGINT_OK
          && 0 < tmp_long && tmp_long <= INT_MAX)