]> git.ipfire.org Git - thirdparty/krb5.git/commit
Minor cleanups relating to size_t being unsigned
authorBen Kaduk <kaduk@mit.edu>
Wed, 27 Jun 2012 20:35:20 +0000 (16:35 -0400)
committerBen Kaduk <kaduk@mit.edu>
Tue, 3 Jul 2012 04:43:45 +0000 (00:43 -0400)
commit149883bec140286d19751fbae7550043f754f4bb
tree01fdc7b1521a2f7b76975b797fea86bb60c8f312
parente7aa25d215a9d4baa95643f2d19e44036e57af72
Minor cleanups relating to size_t being unsigned

In order to use -1 as a sentinel value, we should explicitly cast
to make it clear what we are doing.  It might be better to use
a less convoluted sentinel value such as SIZE_T_MAX, though.

Additionally, since size_t is unsigned and at least as wide as
an int, a loop with int index variable that compares against a
size_t for its termination check could become an infinite loop.
Make the loop index size_t for consistency.
src/plugins/kdb/db2/libdb2/hash/hash_bigkey.c
src/tests/gss-threads/gss-misc.c