From: Vincent van Ravesteijn Date: Sat, 15 Aug 2009 15:47:12 +0000 (+0000) Subject: Fix crash when closing a TabGroup. Probably introduced in r27525 and revealed in... X-Git-Tag: 2.0.0~5719 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=7044b156f07d46d18e01d29466c8ee773adf9769;p=lyx.git Fix crash when closing a TabGroup. Probably introduced in r27525 and revealed in r30933. In setCurrentWorkArea d.current_work_area_ is used which is invalidated by deleting the TabWorkArea. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31054 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/frontends/qt4/GuiView.cpp b/src/frontends/qt4/GuiView.cpp index b89950339d..46cd0b08f5 100644 --- a/src/frontends/qt4/GuiView.cpp +++ b/src/frontends/qt4/GuiView.cpp @@ -2265,6 +2265,7 @@ bool GuiView::dispatch(FuncRequest const & cmd) case LFUN_CLOSE_TAB_GROUP: if (TabWorkArea * twa = d.currentTabWorkArea()) { delete twa; + d.current_work_area_ = 0; twa = d.currentTabWorkArea(); // Switch to the next GuiWorkArea in the found TabWorkArea. if (twa) {