esp8266/esp_mphal: mp_uos_dupterm_deactivate() may raise exception.
So, keep call to it protected via NLR still.
This commit is contained in:
parent
4681b86850
commit
2b05b60bbc
@ -171,11 +171,12 @@ static int call_dupterm_read(void) {
|
|||||||
}
|
}
|
||||||
mp_buffer_info_t bufinfo;
|
mp_buffer_info_t bufinfo;
|
||||||
mp_get_buffer_raise(res, &bufinfo, MP_BUFFER_READ);
|
mp_get_buffer_raise(res, &bufinfo, MP_BUFFER_READ);
|
||||||
nlr_pop();
|
|
||||||
if (bufinfo.len == 0) {
|
if (bufinfo.len == 0) {
|
||||||
mp_uos_deactivate("dupterm: EOF received, deactivating\n", MP_OBJ_NULL);
|
mp_uos_deactivate("dupterm: EOF received, deactivating\n", MP_OBJ_NULL);
|
||||||
|
nlr_pop();
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
nlr_pop();
|
||||||
if (*(byte*)bufinfo.buf == interrupt_char) {
|
if (*(byte*)bufinfo.buf == interrupt_char) {
|
||||||
mp_keyboard_interrupt();
|
mp_keyboard_interrupt();
|
||||||
return -2;
|
return -2;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user