Bug 760834 - Fix mIterationCallback initialization order warning. r=Cwiis
authorOleg Romashin <romaxa@gmail.com>
Mon, 04 Jun 2012 16:49:57 -0700
changeset 95792 ae07e747d7f1c6722be41b2f2935b5377bce472c
parent 95791 730209ed620b547f22a5aa6062fa89331b12b872
child 95793 f0165b3e346866f4103c24ad6e1581dc656c3a81
push id10261
push userdzbarsky@gmail.com
push dateMon, 04 Jun 2012 23:50:52 +0000
treeherdermozilla-inbound@ae07e747d7f1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersCwiis
bugs760834
milestone15.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 760834 - Fix mIterationCallback initialization order warning. r=Cwiis
gfx/gl/GLContext.cpp
gfx/gl/GLLibraryEGL.cpp
--- a/gfx/gl/GLContext.cpp
+++ b/gfx/gl/GLContext.cpp
@@ -904,22 +904,22 @@ BasicTextureImage::Resize(const nsIntSiz
 }
 
 TiledTextureImage::TiledTextureImage(GLContext* aGL,
                                      nsIntSize aSize,
                                      TextureImage::ContentType aContentType,
                                      TextureImage::Flags aFlags)
     : TextureImage(aSize, LOCAL_GL_CLAMP_TO_EDGE, aContentType, aFlags)
     , mCurrentImage(0)
+    , mIterationCallback(nsnull)
     , mInUpdate(false)
     , mRows(0)
     , mColumns(0)
     , mGL(aGL)
     , mTextureState(Created)
-    , mIterationCallback(nsnull)
 {
     mTileSize = (!(aFlags & TextureImage::ForceSingleTile) && mGL->WantsSmallTiles())
         ? 256 : mGL->GetMaxTextureSize();
     if (aSize != nsIntSize(0,0)) {
         Resize(aSize);
     }
 }
 
--- a/gfx/gl/GLLibraryEGL.cpp
+++ b/gfx/gl/GLLibraryEGL.cpp
@@ -43,30 +43,29 @@ static PRLibrary* LoadApitraceLibrary()
     return sApitraceLibrary;
 }
 
 #endif // ANDROID
 
 bool
 GLLibraryEGL::EnsureInitialized()
 {
-    nsresult rv;
-
     if (mInitialized) {
         return true;
     }
 
     mozilla::ScopedGfxFeatureReporter reporter("EGL");
 
 #ifdef XP_WIN
     if (!mEGLLibrary) {
         // On Windows, the GLESv2 and EGL libraries are shipped with libxul and
         // we should look for them there. We have to load the libs in this
         // order, because libEGL.dll depends on libGLESv2.dll.
 
+        nsresult rv;
         nsCOMPtr<nsIFile> libraryFile;
 
         nsCOMPtr<nsIProperties> dirService =
             do_GetService(NS_DIRECTORY_SERVICE_CONTRACTID);
         if (!dirService)
             return false;
 
         rv = dirService->Get(NS_GRE_DIR, NS_GET_IID(nsIFile),