]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Make type for spec variable size as size_t
authorSiddhesh Poyarekar <siddhesh@redhat.com>
Mon, 29 Dec 2014 12:13:19 +0000 (17:43 +0530)
committerSiddhesh Poyarekar <siddhesh@redhat.com>
Mon, 29 Dec 2014 14:26:52 +0000 (19:56 +0530)
ChangeLog
posix/getconf.c
scripts/gen-posix-conf-vars.awk

index ff4b532bfa81f8d436da833102d3881dbf5a48ea..8701732c7118e3d71ad286d5122247e56108ef8f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2014-12-29  Siddhesh Poyarekar  <siddhesh@redhat.com>
 
+       * posix/getconf.c (main): Use size_t for type of I.
+       * scripts-gen-posix-conf-vars.awk (END): Use size_t for type of
+       NSPEC.
+
        * posix/posix-conf-vars.list (SPEC:XBS5): Add sysconf prefix.
        * posix/confstr.c: Define NEED_SPEC_ARRAY to 0.
        * posix/posix-envs.def: Likewise.
index bcde4c58a19fd38c51eba582ffdd85431fdfe3ba..45eabb2a2cab194c5639ecc229d00e6d599630f0 100644 (file)
@@ -528,7 +528,7 @@ environment SPEC.\n\n"));
   /* Check for the specifications we know.  */
   if (spec != NULL)
     {
-      int i;
+      size_t i;
       for (i = 0; i < nspecs; ++i)
        if (strcmp (spec, specs[i].name) == 0)
          break;
index 0eca55d536bd7f70e41f2179bf193c667a117d63..007cd744deab4bae40520c9d98d2771b738db929 100644 (file)
@@ -84,6 +84,6 @@ END {
     printf "    { \"%s\", %s },\n", s, spec[s]
   }
   print "  };"
-  print "static const int nspecs = sizeof (specs) / sizeof (specs[0]);"
+  print "static const size_t nspecs = sizeof (specs) / sizeof (specs[0]);"
   print "#endif"
 }