]> git.lyx.org Git - lyx.git/blobdiff - src/Text2.cpp
Fix a crash when closing tabs
[lyx.git] / src / Text2.cpp
index f77bfaa3de54f93bd93775206a5105733dd79eb8..4959a3fc814d259b34366b3e0854e31c1ba3f27f 100644 (file)
@@ -916,6 +916,7 @@ bool Text::deleteEmptyParagraphMechanism(Cursor & cur,
        if (cur.depth() >= old.depth()) {
                CursorSlice & curslice = cur[old.depth() - 1];
                if (&curslice.inset() == &old.inset()
+                   && curslice.idx() == old.idx()
                    && curslice.pit() > old.pit()) {
                        --curslice.pit();
                        // since a paragraph has been deleted, all the