Skip to content

Commit 4b597a1

Browse files
dpgeorgepfalcon
authored andcommitted
esp8266: Reset term_obj on reboot.
Also, term_obj can be NULL if socket enables REPL duplication signalling before os.dupterm is called, so it should be checked.
1 parent 98af891 commit 4b597a1

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

esp8266/main.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ STATIC void mp_reset(void) {
5252
memset(MP_STATE_PORT(fs_user_mount), 0, sizeof(MP_STATE_PORT(fs_user_mount)));
5353
#endif
5454
MP_STATE_PORT(mp_kbd_exception) = mp_obj_new_exception(&mp_type_KeyboardInterrupt);
55+
MP_STATE_PORT(term_obj) = MP_OBJ_NULL;
5556
#if MICROPY_MODULE_FROZEN
5657
pyexec_frozen_module("boot");
5758
#endif

0 commit comments

Comments
 (0)