sw/source/core/view/vnew.cxx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
New commits: commit de9bcd167b059e00818304626c0cadaa330738a4 Author: Noel Grandin <noel.gran...@collabora.co.uk> Date: Fri Jan 26 10:29:43 2018 +0200 tdf#115221 crash in printing and comment not wonderfully happy with this fix, because we're changing the delete ordering here, but the origin of this bug was commit a754294ac7a902fe96fbbd6b8b6824a360d6b248 use rtl::Reference in SwDocFac instead of manual acquire/releas and commit cc483d0470dbf0d01e4da818b148ff0b851c5187 (patch) tdf#112292 - fix memory leak and use more auto ref counting in sw so the delete ordering was obviously messed up in those already, and we have such a morass of callbacks here, I can't see where else to fix it. I tried to add a couple more "getDoc() != nullptr" checks, but we still ended up crashing with an SwViewShell that had a bad pLayoutAccess pointer. Change-Id: I4aa39d58ae25bed41e3fd2c32c6d53659012ec10 Reviewed-on: https://gerrit.libreoffice.org/48658 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/sw/source/core/view/vnew.cxx b/sw/source/core/view/vnew.cxx index 2998ffb131f8..4c74acecdd09 100644 --- a/sw/source/core/view/vnew.cxx +++ b/sw/source/core/view/vnew.cxx @@ -324,9 +324,7 @@ SwViewShell::~SwViewShell() if ( mxDoc.get() ) { - auto x = mxDoc->getReferenceCount(); - mxDoc.clear(); - if( x > 1 ) + if( mxDoc->getReferenceCount() > 1 ) GetLayout()->ResetNewLayout(); } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits