Re: [PATCH] Fix calloc() behaviour in case of overflow

2021-04-20 Thread Gedare Bloom
Looks good. On Tue, Apr 20, 2021, 12:33 PM Sebastian Huber < sebastian.hu...@embedded-brains.de> wrote: > The multiplication to calculate the length of the memory area to > allocate may overflow. Return NULL in case of an overflow. > > Close #4389. > --- > cpukit/libcsupport/src/calloc.c

[PATCH] Fix calloc() behaviour in case of overflow

2021-04-20 Thread Sebastian Huber
The multiplication to calculate the length of the memory area to allocate may overflow. Return NULL in case of an overflow. Close #4389. --- cpukit/libcsupport/src/calloc.c | 13 - cpukit/libcsupport/src/rtemscalloc.c | 9 - testsuites/libtests/malloctest/init.c | 23