Bug 782971 - Fix crash resulting from not initializing an argument in ShadowThebesLayerOGL::Swap(). r=cjones
authorJustin Lebar <justin.lebar@gmail.com>
Wed, 15 Aug 2012 14:36:44 -0400
changeset 102457 4db58ba7848f9d74bfea774df7712026987292b3
parent 102456 194bf5cfd25fec90357d98422041b03d4a0fa3d2
child 102458 340f7af0fb8e7f4f17c916b1337c3e46223795d6
push id23287
push userryanvm@gmail.com
push dateThu, 16 Aug 2012 01:37:50 +0000
treeherdermozilla-central@50e4ff05741e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerscjones
bugs782971
milestone17.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 782971 - Fix crash resulting from not initializing an argument in ShadowThebesLayerOGL::Swap(). r=cjones
gfx/layers/opengl/ThebesLayerOGL.cpp
--- a/gfx/layers/opengl/ThebesLayerOGL.cpp
+++ b/gfx/layers/opengl/ThebesLayerOGL.cpp
@@ -999,16 +999,17 @@ ShadowThebesLayerOGL::Swap(const ThebesB
                            nsIntRegion* aNewBackValidRegion,
                            OptionalThebesBuffer* aReadOnlyFront,
                            nsIntRegion* aFrontUpdatedRegion)
 {
   if (mDestroyed) {
     // Don't drop buffers on the floor.
     *aNewBack = aNewFront;
     *aNewBackValidRegion = aNewFront.rect();
+    *aReadOnlyFront = null_t();
     return;
   }
 
   if (IsSurfaceDescriptorValid(mBufferDescriptor)) {
     AutoOpenSurface currentFront(OPEN_READ_ONLY, mBufferDescriptor);
     AutoOpenSurface newFront(OPEN_READ_ONLY, aNewFront.buffer());
     if (currentFront.Size() != newFront.Size()) {
       // The buffer changed size making the current front buffer