mirror of
git://git.yoctoproject.org/linux-yocto.git
synced 2026-01-10 11:58:55 +01:00
reallocarray() is a safer variant of realloc which checks for multiplication overflow in case of array allocation. Since it's not available in Glibc < 2.26 import kernel's overflow.h and add a static inline implementation when needed. Use feature detection to probe for existence of reallocarray. Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Reviewed-by: Quentin Monnet <quentin.monnet@netronome.com> Reviewed-by: Jiong Wang <jiong.wang@netronome.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> |
||
|---|---|---|
| .. | ||
| sched | ||
| unaligned | ||
| atomic.h | ||
| bitmap.h | ||
| bitops.h | ||
| bug.h | ||
| compiler-gcc.h | ||
| compiler.h | ||
| coresight-pmu.h | ||
| debug_locks.h | ||
| delay.h | ||
| err.h | ||
| export.h | ||
| filter.h | ||
| ftrace.h | ||
| gfp.h | ||
| hardirq.h | ||
| hash.h | ||
| hashtable.h | ||
| interrupt.h | ||
| irqflags.h | ||
| jhash.h | ||
| kallsyms.h | ||
| kern_levels.h | ||
| kernel.h | ||
| linkage.h | ||
| list.h | ||
| lockdep.h | ||
| log2.h | ||
| module.h | ||
| mutex.h | ||
| overflow.h | ||
| poison.h | ||
| proc_fs.h | ||
| rbtree_augmented.h | ||
| rbtree.h | ||
| rcu.h | ||
| refcount.h | ||
| seq_file.h | ||
| spinlock.h | ||
| stacktrace.h | ||
| string.h | ||
| stringify.h | ||
| time64.h | ||
| types.h | ||