]> git.ipfire.org Git - thirdparty/krb5.git/commit
Ensure defined behavior in k5_kt_have_match() 1464/head
authorGreg Hudson <ghudson@mit.edu>
Sun, 12 Oct 2025 18:03:06 +0000 (14:03 -0400)
committerGreg Hudson <ghudson@mit.edu>
Wed, 15 Oct 2025 06:08:11 +0000 (02:08 -0400)
commit4e5d98464e83fd90faa55c2e11bec813a28c89ee
tree4d5d3699f761cc6dce7cfa6d790cef74b4d21caa
parent67abc25fa9deadd3638bb1b78373d2f08de0d54d
Ensure defined behavior in k5_kt_have_match()

match_entries() in ktfns.c admits uninitialized use of match if the
loop runs for zero iterations (the keytab is valid but contains no
entries).  Initialize match to false to properly handle this case.
Fixes a -Werror compilation failure on macOS 10.6.8 reported by Sergey
Fedorov.
src/lib/krb5/keytab/ktfns.c