mbed_error.c: Fixed another bug of possible stack overflow.

pull/11332/head
Andrew Chong 2019-09-06 16:49:09 +08:00
parent bd9ec8b6d7
commit c257c5f0c7
1 changed files with 1 additions and 1 deletions

View File

@ -509,7 +509,7 @@ static void print_stack_dump_core(uint32_t stack_start, uint32_t stack_size, uin
mbed_error_printf("\n0x%08" PRIX32 ":", st);
for (int i = 0; i < STACK_DUMP_WIDTH; i++) {
uint32_t st_cur = st + i * sizeof(int);
if (st_cur > st_end) {
if (st_cur >= st_end) {
break;
}
uint32_t st_val = *((uint32_t *)st_cur);