diff options
| author | Scott Shawcroft <scott@tannewt.org> | 2018-08-02 14:45:21 -0700 |
|---|---|---|
| committer | Scott Shawcroft <scott@tannewt.org> | 2018-08-02 14:45:21 -0700 |
| commit | 4b247eacd85ba79d6fbb72d217dc5a13e85a5ed9 (patch) | |
| tree | 7dc225e3c0bdbffebe5a464811fe44898617c2f1 /supervisor/shared | |
| parent | 5704bc8c93e36ded3e7dc8e46aa836e7a2acee15 (diff) | |
Add todo for handling improper free.
Diffstat (limited to 'supervisor/shared')
| -rwxr-xr-x | supervisor/shared/memory.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/supervisor/shared/memory.c b/supervisor/shared/memory.c index 051f55a70..34c5dfb6f 100755 --- a/supervisor/shared/memory.c +++ b/supervisor/shared/memory.c @@ -51,6 +51,10 @@ void free_memory(supervisor_allocation* allocation) { break; } } + if (!found) { + // Bad! + // TODO(tannewt): Add a way to escape into safe mode on error. + } if (allocation->ptr == high_address) { high_address += allocation->length / 4; for (index++; index < CIRCUITPY_SUPERVISOR_ALLOC_COUNT; index++) { |
