diff --git a/indra/llmath/v3color.h b/indra/llmath/v3color.h
index 60353bea6e468d79f09b4d41398572d82c3a312d..0b3b4ea3e10b8390a084615bfc15ef2f3a75b8cc 100644
--- a/indra/llmath/v3color.h
+++ b/indra/llmath/v3color.h
@@ -485,7 +485,7 @@ inline const LLColor3 srgbColor3(const LLColor3 &a) {
 	return srgbColor;
 }
 
-inline const LLColor3 linearColor3(const F32* v) {
+inline const LLColor3 linearColor3p(const F32* v) {
     LLColor3 linearColor;
     linearColor.mV[0] = sRGBtoLinear(v[0]);
     linearColor.mV[1] = sRGBtoLinear(v[1]);
@@ -496,12 +496,12 @@ inline const LLColor3 linearColor3(const F32* v) {
 
 template<class T>
 inline const LLColor3 linearColor3(const T& a) {
-    return linearColor3(a.mV);
+    return linearColor3p(a.mV);
 }
 
 template<class T>
 inline const LLVector3 linearColor3v(const T& a) {
-    return LLVector3(linearColor3(a.mV).mV);
+    return LLVector3(linearColor3p(a.mV).mV);
 }
 
 #endif
diff --git a/indra/newview/llsettingsvo.cpp b/indra/newview/llsettingsvo.cpp
index ddd9c568411c502635c18dc787ad237eb6152183..f9b7c749b36322e35ba1afb5f1e23803dcfad620 100644
--- a/indra/newview/llsettingsvo.cpp
+++ b/indra/newview/llsettingsvo.cpp
@@ -968,7 +968,7 @@ void LLSettingsVOWater::applySpecial(void *ptarget, bool force)
         LLColor4 fog_color(env.getCurrentWater()->getWaterFogColor());
         shader->uniform4fv(LLShaderMgr::WATER_FOGCOLOR, fog_color.mV);
 
-        shader->uniform3fv(LLShaderMgr::WATER_FOGCOLOR_LINEAR, linearColor3(fog_color.mV).mV);
+        shader->uniform3fv(LLShaderMgr::WATER_FOGCOLOR_LINEAR, linearColor3(fog_color).mV);
 
         F32 blend_factor = env.getCurrentWater()->getBlendFactor();
         shader->uniform1f(LLShaderMgr::BLEND_FACTOR, blend_factor);
diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp
index 8ef65b665d5000b39d02ae482d30992d674fd9de..5c5a5ba0d1e0d9e744a53c7d363e191f0e048228 100644
--- a/indra/newview/llviewerwindow.cpp
+++ b/indra/newview/llviewerwindow.cpp
@@ -5162,7 +5162,7 @@ BOOL LLViewerWindow::simpleSnapshot(LLImageRaw* raw, S32 image_width, S32 image_
     LLRenderTarget scratch_space;
     U32 color_fmt = GL_RGBA;
     const bool use_depth_buffer = true;
-    const bool use_stencil_buffer = true;
+    const bool use_stencil_buffer = false;
     if (scratch_space.allocate(image_width, image_height, color_fmt, use_depth_buffer, use_stencil_buffer))
     {
         if (gPipeline.allocateScreenBuffer(image_width, image_height))