diff --git a/src/frontends/qt4/GuiView.cpp b/src/frontends/qt4/GuiView.cpp index cfdfa7f35a..01a4cb5749 100644 --- a/src/frontends/qt4/GuiView.cpp +++ b/src/frontends/qt4/GuiView.cpp @@ -1425,9 +1425,20 @@ void GuiView::errors(string const & error_type, bool from_master) if (!bv) return; +#if EXPORT_in_THREAD && (QT_VERSION >= 0x040400) + // We are called with from_master == false by default, so we + // have to figure out whether that is the case or not. + ErrorList & el = bv->buffer().errorList(error_type); + if (el.empty()) { + el = bv->buffer().masterBuffer()->errorList(error_type); + from_master = true; + } +#else ErrorList & el = from_master ? bv->buffer().masterBuffer()->errorList(error_type) : bv->buffer().errorList(error_type); +#endif + if (el.empty()) return;