]> git.lyx.org Git - lyx.git/blobdiff - src/BufferView.C
formatting
[lyx.git] / src / BufferView.C
index ede9d687b86dc0041947a48755c2ff0116f3337d..b1cfd99a49c111856ec1b9f8a51266cdea1cf0b1 100644 (file)
@@ -335,6 +335,10 @@ bool BufferView::multiParSel()
 
 bool BufferView::update(Update::flags flags)
 {
+       // last_inset_ points to the last visited inset. This pointer may become
+       // invalid becuase of keyboard editing. Since all such operations
+       // causes screen update(), I reset last_inset_ to avoid such a problem.
+       last_inset_ = 0;
        // This is close to a hot-path.
        if (lyxerr.debugging(Debug::DEBUG)) {
                lyxerr[Debug::DEBUG]