diff --git a/Telegram/SourceFiles/core/crash_report_window.cpp b/Telegram/SourceFiles/core/crash_report_window.cpp index df46183917..5a15c67cd2 100644 --- a/Telegram/SourceFiles/core/crash_report_window.cpp +++ b/Telegram/SourceFiles/core/crash_report_window.cpp @@ -11,6 +11,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL #include "core/launcher.h" #include "core/sandbox.h" #include "core/update_checker.h" +#include "core/ui_integration.h" #include "window/main_window.h" #include "platform/platform_specific.h" #include "base/zlib_help.h" @@ -252,7 +253,11 @@ LastCrashedWindow::LastCrashedWindow( , _launch(std::move(launch)) { excludeReportUsername(); - if (!cInstallBetaVersion() && !cAlphaVersion()) { // currently accept crash reports only from testers + if (!cInstallBetaVersion() && !cAlphaVersion()) { + // Currently accept crash reports only from testers. + _sendingState = SendingNoReport; + } else if (Core::OpenGLLastCheckFailed()) { + // Nothing we can do right now with graphics driver crashes in GL. _sendingState = SendingNoReport; } if (_sendingState != SendingNoReport) { diff --git a/Telegram/SourceFiles/core/ui_integration.cpp b/Telegram/SourceFiles/core/ui_integration.cpp index 043854828f..81bf27ab5a 100644 --- a/Telegram/SourceFiles/core/ui_integration.cpp +++ b/Telegram/SourceFiles/core/ui_integration.cpp @@ -120,7 +120,7 @@ void UiIntegration::openglCheckFinish() { } bool UiIntegration::openglLastCheckFailed() { - return QFile::exists(OpenGLCheckFilePath()); + return OpenGLLastCheckFailed(); } void UiIntegration::textActionsUpdated() { @@ -320,4 +320,8 @@ QString UiIntegration::phraseFormattingMonospace() { return tr::lng_menu_formatting_monospace(tr::now); } +bool OpenGLLastCheckFailed() { + return QFile::exists(OpenGLCheckFilePath()); +} + } // namespace Core diff --git a/Telegram/SourceFiles/core/ui_integration.h b/Telegram/SourceFiles/core/ui_integration.h index 391e400743..c685540189 100644 --- a/Telegram/SourceFiles/core/ui_integration.h +++ b/Telegram/SourceFiles/core/ui_integration.h @@ -75,6 +75,6 @@ public: }; -[[nodiscard]] bool OpenglLastCheckFailed(); +[[nodiscard]] bool OpenGLLastCheckFailed(); } // namespace Core