summaryrefslogtreecommitdiff
path: root/indra/llrender/llgl.cpp
diff options
context:
space:
mode:
authorAndrey Lihatskiy <118752495+marchcat@users.noreply.github.com>2026-07-17 12:57:48 +0300
committerGitHub <noreply@github.com>2026-07-17 12:57:48 +0300
commit8a22869dfad731f8cd9f4164a7a2b57cd70af51c (patch)
tree1d1133495ccf193a0b36d903db1407243935615f /indra/llrender/llgl.cpp
parentf5e788b1b4ff5fb45f20ee5fa5daad7cca42069f (diff)
parent8f05370e7ebccd086b5d4791a1b2dc052361b026 (diff)
Merge pull request #6016 from secondlife/marchcat/slua-26.3
SLua PV <- 26.3 merge
Diffstat (limited to 'indra/llrender/llgl.cpp')
-rw-r--r--indra/llrender/llgl.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/indra/llrender/llgl.cpp b/indra/llrender/llgl.cpp
index 5357a79bae..b43f448305 100644
--- a/indra/llrender/llgl.cpp
+++ b/indra/llrender/llgl.cpp
@@ -2423,6 +2423,12 @@ void clear_glerror()
glGetError();
}
+void drain_glerror()
+{
+ // bounded: a lost/reset context can return errors indefinitely
+ for (S32 i = 0; i < 16 && glGetError() != GL_NO_ERROR; ++i) {}
+}
+
///////////////////////////////////////////////////////////////
//
// LLGLState