(fts_open): Put new (2006-01-04) maxarglen declaration and uses in their
authorJim Meyering <jim@meyering.net>
Wed, 11 Jan 2006 16:29:35 +0000 (16:29 +0000)
committerJim Meyering <jim@meyering.net>
Wed, 11 Jan 2006 16:29:35 +0000 (16:29 +0000)
own block, so pre-c99 compilers don't object.

lib/fts.c

index 94d8de9..6cf393c 100644 (file)
--- a/lib/fts.c
+++ b/lib/fts.c
@@ -242,9 +242,11 @@ fts_open (char * const *argv,
 #ifndef MAXPATHLEN
 # define MAXPATHLEN 1024
 #endif
-       size_t maxarglen = fts_maxarglen(argv);
-       if (! fts_palloc(sp, MAX(maxarglen, MAXPATHLEN)))
-               goto mem1;
+       {
+         size_t maxarglen = fts_maxarglen(argv);
+         if (! fts_palloc(sp, MAX(maxarglen, MAXPATHLEN)))
+                 goto mem1;
+       }
 
        /* Allocate/initialize root's parent. */
        if ((parent = fts_alloc(sp, "", 0)) == NULL)