From d292ec7ee065c50e415c0ef06664ab6d428a022b Mon Sep 17 00:00:00 2001
From: Graham Linden <graham@lindenlab.com>
Date: Tue, 30 Oct 2018 21:25:52 +0100
Subject: [PATCH] Better OSX clean up.

---
 indra/newview/lldrawpoolsky.cpp | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)

diff --git a/indra/newview/lldrawpoolsky.cpp b/indra/newview/lldrawpoolsky.cpp
index a04ebcddee9..4d4711d7c9b 100644
--- a/indra/newview/lldrawpoolsky.cpp
+++ b/indra/newview/lldrawpoolsky.cpp
@@ -98,18 +98,10 @@ void LLDrawPoolSky::render(S32 pass)
 	}
 	
 
-	LLGLSPipelineSkyBox gls_skybox;
-
-	LLGLDepthTest gls_depth(GL_TRUE, GL_FALSE);
-
-	LLGLSquashToFarClip far_clip;
+	LLGLSPipelineDepthTestSkyBox gls_skybox(true, false);
 
 	LLGLEnable fog_enable( (mVertexShaderLevel < 1 && LLViewerCamera::getInstance()->cameraUnderWater()) ? GL_FOG : 0);
 
-	gPipeline.disableLights();
-	
-	LLGLDisable clip(GL_CLIP_PLANE0);
-
 	gGL.pushMatrix();
 	LLVector3 origin = LLViewerCamera::getInstance()->getOrigin();
 	gGL.translatef(origin.mV[0], origin.mV[1], origin.mV[2]);
-- 
GitLab