diff --git a/src/io.c b/src/io.c index f9e98ae..e0a8502 100644 --- a/src/io.c +++ b/src/io.c @@ -857,6 +857,14 @@ void io_reload_data(void) recur_event_llist_init(); todo_init_list(); + /* + * Temporarily reinitialize the todo list box without any items to make + * sure wins_unprepare_external() does not fail when it is called after + * executing the pre-load hook. + */ + ui_todo_load_items(); + ui_todo_sel_reset(); + io_load_data(NULL); io_unset_modified(); ui_todo_load_items();