Commit Graph

12 Commits

Author SHA1 Message Date
Brennan Ashton e87617f9fa nxstyle: fixup style issues in mm_realloc.c
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-06-29 14:56:26 -07:00
Brennan Ashton fcd6e1c7eb mm: Do not memcopy more than oldsize when realloc
When realloc up from a mem area to a larger one where a new node
is needed. The the larger memory region is copied from the source
this can both leak data as well as cause memory faults accesssing
invalid data.

This was first reported by Kwonsk

Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-06-29 14:56:26 -07:00
YAMAMOTO Takashi 46ad645efc mm: Add a bunch of assertions 2020-02-13 08:21:18 -06:00
Gregory Nutt 1382ea5447 mm/: Coding style clean-up
Run tools/nxstyle against all C files under mm/ and correct coding standard violations.
2020-02-13 15:16:53 +01:00
YAMAMOTO Takashi 710da6022d Fix comment typos 2020-02-12 20:39:47 -06:00
Gregory Nutt 0064dc52e5 realloc(): When realloc() has to fall back to calling malloc(), size including overhead was being provided to malloc(), causing a slightly larger allocation than needed. Noted by initialkjc@yahoo.com 2017-03-28 07:23:46 -06:00
Gregory Nutt c4493528a1 Remove some empty file section section header comments 2016-02-17 18:57:35 -06:00
Gregory Nutt 06cd5b2fcc mm, audio, crypto, graphics: Fix various spacing/alignment issues 2015-10-08 09:10:22 -06:00
Paul A. Patience 9f108b7b63 Fix issues detected by clang 2015-09-10 20:59:43 -04:00
Gregory Nutt 9ac09db800 More fixes to problems noted by cppcheck. Some are kind of risky; some are real bugs. 2014-11-25 13:46:14 -06:00
Gregory Nutt b33c2d9cef Move include/nuttx/mm.h to include/nuttx/mm/mm.h 2014-09-24 07:29:09 -06:00
Gregory Nutt 3464089542 Move core heap allocator logic from mm/. to mm/mm_heap/. 2014-09-22 10:53:50 -06:00