From 9ddf64c65183960ffed4fe61c5d85e8bacaea030 Mon Sep 17 00:00:00 2001 From: Alexander Gavriliuk Date: Fri, 5 Jul 2024 18:46:30 +0200 Subject: #1931 BugSplat Crash: SecondLifeViewer!LLRenderTarget::release(387) --- indra/llrender/llrendertarget.cpp | 4 ++++ indra/llrender/llrendertarget.h | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'indra/llrender') diff --git a/indra/llrender/llrendertarget.cpp b/indra/llrender/llrendertarget.cpp index 60159a0497..410efe9a70 100644 --- a/indra/llrender/llrendertarget.cpp +++ b/indra/llrender/llrendertarget.cpp @@ -50,6 +50,7 @@ void check_framebuffer_status() } } +bool LLRenderTarget::sInitFailed = false; bool LLRenderTarget::sUseFBO = false; U32 LLRenderTarget::sCurFBO = 0; @@ -352,6 +353,9 @@ void LLRenderTarget::release() LL_PROFILE_ZONE_SCOPED_CATEGORY_DISPLAY; llassert(!isBoundInStack()); + if (sInitFailed) + return; + if (mDepth) { LLImageGL::deleteTextures(1, &mDepth); diff --git a/indra/llrender/llrendertarget.h b/indra/llrender/llrendertarget.h index a1adf93fa1..fc78f059e0 100644 --- a/indra/llrender/llrendertarget.h +++ b/indra/llrender/llrendertarget.h @@ -61,7 +61,9 @@ class LLRenderTarget { public: - //whether or not to use FBO implementation + // Whether app initialization failed + static bool sInitFailed; + // Whether or not to use FBO implementation static bool sUseFBO; static U32 sBytesAllocated; static U32 sCurFBO; -- cgit v1.2.3