X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FTocBackend.cpp;h=f46b3c8418ba6c0514d5708c107cdde8f77b8873;hb=26910d5ec49395d1372dd5b9259f1bf6ed23de0a;hp=c8bf4adf4853a96911596e1f1b042e416fd0d37e;hpb=86994bf75320524ec656fd70950633c83d445a6c;p=lyx.git diff --git a/src/TocBackend.cpp b/src/TocBackend.cpp index c8bf4adf48..f46b3c8418 100644 --- a/src/TocBackend.cpp +++ b/src/TocBackend.cpp @@ -105,7 +105,7 @@ Toc const & TocBackend::toc(string const & type) const { // Is the type already supported? TocList::const_iterator it = tocs_.find(type); - LASSERT(it != tocs_.end(), /**/); + LASSERT(it != tocs_.end(), { static Toc dummy; return dummy; }); return it->second; } @@ -182,7 +182,8 @@ TocIterator TocBackend::item(string const & type, { TocList::const_iterator toclist_it = tocs_.find(type); // Is the type supported? - LASSERT(toclist_it != tocs_.end(), /**/); + // We will try to make the best of it in release mode + LASSERT(toclist_it != tocs_.end(), toclist_it = tocs_.begin()); return toclist_it->second.item(dit); }