aboutsummaryrefslogtreecommitdiffstats
path: root/lib/strncpy_from_user.c
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <[email protected]>2020-01-17 22:45:12 +0000
committerMatthew Wilcox (Oracle) <[email protected]>2020-01-18 03:32:24 +0000
commit430f24f94c8a174d411a550d7b5529301922e67a (patch)
tree7a23f31ee6f3bca6a09e1ce0c23fa62d4e65c5e1 /lib/strncpy_from_user.c
parentXArray: Add wrappers for nested spinlocks (diff)
downloadkernel-430f24f94c8a174d411a550d7b5529301922e67a.tar.gz
kernel-430f24f94c8a174d411a550d7b5529301922e67a.zip
XArray: Fix infinite loop with entry at ULONG_MAX
If there is an entry at ULONG_MAX, xa_for_each() will overflow the 'index + 1' in xa_find_after() and wrap around to 0. Catch this case and terminate the loop by returning NULL. Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Cc: [email protected]
Diffstat (limited to 'lib/strncpy_from_user.c')
0 files changed, 0 insertions, 0 deletions