From decc411b6b6dd38ff6a123573987de29d8522a6c Mon Sep 17 00:00:00 2001 From: Abdelrazak Younes Date: Wed, 13 Feb 2008 12:37:11 +0000 Subject: [PATCH] rev 22973: correct fix. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22974 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/TextClass.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/TextClass.cpp b/src/TextClass.cpp index ec98ff811a..18d28752f9 100644 --- a/src/TextClass.cpp +++ b/src/TextClass.cpp @@ -241,8 +241,11 @@ bool TextClass::read(FileName const & filename, ReadType rt) lex.setStream(ss); Layout lay; lay.setName(emptylayout_); - /*bool error =*/ readStyle(lex, lay); - BOOST_ASSERT(!error); + if (!readStyle(lex, lay)) { + // FIXME: Couldn't we provide some feedback to the user here? + // Use ExceptionMessage maybe? + BOOST_ASSERT(false); + } layoutlist_.push_back(boost::shared_ptr(new Layout(lay))); }