summaryrefslogtreecommitdiff
path: root/indra/llrender
diff options
context:
space:
mode:
authorruslantproductengine <ruslantproductengine@lindenlab.com>2016-03-10 19:50:12 +0200
committerruslantproductengine <ruslantproductengine@lindenlab.com>2016-03-10 19:50:12 +0200
commit173886fec32f2f5a8b63e81997f5929b02ddc8c9 (patch)
tree72f633b0b754eca77da524b0e8ffbe46bab8c311 /indra/llrender
parentdebc51af6b6a35f7f635be9483a3bc4d0846a90d (diff)
MAINT-1109 FIXED Toggling graphics options causes viewer memory to increase, eventually causing the rendering pipeline to fall over and crashing the viewer
Patchset #2
Diffstat (limited to 'indra/llrender')
-rwxr-xr-xindra/llrender/llglslshader.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/indra/llrender/llglslshader.cpp b/indra/llrender/llglslshader.cpp
index 52b8de8365..750e35a71a 100755
--- a/indra/llrender/llglslshader.cpp
+++ b/indra/llrender/llglslshader.cpp
@@ -345,15 +345,10 @@ void LLGLSLShader::unloadInternal()
GLhandleARB obj[1024];
GLsizei count;
- glGetAttachedObjectsARB(mProgramObject, 1024, &count, obj);
+ glGetAttachedObjectsARB(mProgramObject, sizeof(obj)/sizeof(obj[0]), &count, obj);
for (GLsizei i = 0; i < count; i++)
{
-#if !LL_DARWIN
- if (glIsProgramARB(obj[i]))
-#endif
- {
- glDeleteObjectARB(obj[i]);
- }
+ glDeleteObjectARB(obj[i]);
}
glDeleteObjectARB(mProgramObject);