]> git.lyx.org Git - features.git/blobdiff - src/DocIterator.cpp
Check that DocIterator::sanitize only adds editable insets
[features.git] / src / DocIterator.cpp
index 859aae9ddda07f00956c1397cd1d7aec33264ddb..e574115c31be85de4349a1ef7ab1e60db2e19f2a 100644 (file)
@@ -555,6 +555,11 @@ void DocIterator::sanitize()
                        fixIfBroken();
                        break;
                }
+               if (!inset->editable()) {
+                       LYXERR0("Inset found on cursor stack is not editable.");
+                       fixIfBroken();
+                       break;
+               }
                push_back(sl[i]);
                top().inset_ = inset;
                if (fixIfBroken())