=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/tmux/window.c,v retrieving revision 1.288 retrieving revision 1.289 diff -u -r1.288 -r1.289 --- src/usr.bin/tmux/window.c 2024/02/13 08:03:50 1.288 +++ src/usr.bin/tmux/window.c 2024/03/21 11:30:42 1.289 @@ -1,4 +1,4 @@ -/* $OpenBSD: window.c,v 1.288 2024/02/13 08:03:50 nicm Exp $ */ +/* $OpenBSD: window.c,v 1.289 2024/03/21 11:30:42 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott @@ -340,7 +340,7 @@ { log_debug("window @%u destroyed (%d references)", w->id, w->references); - window_unzoom(w); + window_unzoom(w, 0); RB_REMOVE(windows, &windows, w); if (w->layout_root != NULL) @@ -666,7 +666,7 @@ } int -window_unzoom(struct window *w) +window_unzoom(struct window *w, int notify) { struct window_pane *wp; @@ -683,8 +683,10 @@ wp->saved_layout_cell = NULL; } layout_fix_panes(w, NULL); - notify_window("window-layout-changed", w); + if (notify) + notify_window("window-layout-changed", w); + return (0); } @@ -697,7 +699,7 @@ w->flags |= WINDOW_WASZOOMED; else w->flags &= ~WINDOW_WASZOOMED; - return (window_unzoom(w) == 0); + return (window_unzoom(w, 1) == 0); } int