diff -rup a/terminal/terminal-window.c b/terminal/terminal-window.c --- a/terminal/terminal-window.c 2024-01-23 20:10:59.000000000 +0100 +++ b/terminal/terminal-window.c 2024-02-07 12:31:32.599468621 +0100 @@ -2573,11 +2573,11 @@ terminal_window_do_close_tab (TerminalSc gtk_notebook_set_current_page (notebook, page_num); } - gtk_widget_destroy (GTK_WIDGET (screen)); - /* reconnect the accels of the active terminal */ if (screen != window->priv->active) terminal_screen_widget_append_accels (window->priv->active, window->priv->accel_group); + + gtk_widget_destroy (GTK_WIDGET (screen)); }