diff --git a/src/output_xhtml.cpp b/src/output_xhtml.cpp
index 5a06b2f0a3..6e4343cbd7 100644
--- a/src/output_xhtml.cpp
+++ b/src/output_xhtml.cpp
@@ -344,7 +344,7 @@ bool XHTMLStream::closeFontTags()
tag_stack_.pop_back();
// this shouldn't happen, since then the font tags
// weren't in any other tag.
- LBUFERR(!tag_stack_.empty());
+ LASSERT(!tag_stack_.empty(), return true);
curtag = tag_stack_.back();
}