aboutsummaryrefslogtreecommitdiffstats
path: root/lib/mpi/mpi-gcd.c
diff options
context:
space:
mode:
authorDavid Howells <[email protected]>2025-11-29 00:40:11 +0000
committerLinus Torvalds <[email protected]>2025-11-29 00:48:18 +0000
commit19eef1d98eeda3745df35839190b7d4a4adea656 (patch)
tree8d0b29825fa335ad0b98a8fc9e09d34d87d5e96b /lib/mpi/mpi-gcd.c
parentMerge tag 'spi-fix-v6.18-rc7' of git://git.kernel.org/pub/scm/linux/kernel/gi... (diff)
downloadkernel-19eef1d98eeda3745df35839190b7d4a4adea656.tar.gz
kernel-19eef1d98eeda3745df35839190b7d4a4adea656.zip
afs: Fix uninit var in afs_alloc_anon_key()
Fix an uninitialised variable (key) in afs_alloc_anon_key() by setting it to cell->anonymous_key. Without this change, the error check may return a false failure with a bad error number. Most of the time this is unlikely to happen because the first encounter with afs_alloc_anon_key() will usually be from (auto)mount, for which all subsequent operations must wait - apart from other (auto)mounts. Once the call->anonymous_key is allocated, all further calls to afs_request_key() will skip the call to afs_alloc_anon_key() for that cell. Fixes: d27c71257825 ("afs: Fix delayed allocation of a cell's anonymous key") Reported-by: Paulo Alcantra <[email protected]> Signed-off-by: David Howells <[email protected]> Reviewed-by: Paulo Alcantara <[email protected]> cc: Marc Dionne <[email protected]> cc: [email protected] cc: [email protected] cc: [email protected] Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'lib/mpi/mpi-gcd.c')
0 files changed, 0 insertions, 0 deletions