]> git.lyx.org Git - features.git/commitdiff
We need to do the sanity check here, too, as we do in
authorRichard Heck <rgheck@comcast.net>
Fri, 26 Nov 2010 16:45:58 +0000 (16:45 +0000)
committerRichard Heck <rgheck@comcast.net>
Fri, 26 Nov 2010 16:45:58 +0000 (16:45 +0000)
Inset::getLayout(). Fixes the crash in bug #7069. My bad.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36515 a592a061-630c-0410-9148-cb99ea01b6c8

src/insets/InsetFlex.cpp

index 6d64c3f8ead6a4f839e1a93f26e2a67b9e0d2b70..cf3741263c7f4edb77738b46924842681ee7008d 100644 (file)
@@ -45,6 +45,9 @@ InsetFlex::InsetFlex(InsetFlex const & in)
 
 InsetLayout const & InsetFlex::getLayout() const
 {
+       if (!buffer_)
+               return DocumentClass::plainInsetLayout();
+
        DocumentClass const & dc = buffer().params().documentClass();
        docstring const dname = from_utf8(name_); 
        if (dc.hasInsetLayout(dname))