Build fix attempt number 2.
authorscroggo@google.com <scroggo@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Wed, 1 May 2013 21:40:58 +0000 (21:40 +0000)
committerscroggo@google.com <scroggo@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Wed, 1 May 2013 21:40:58 +0000 (21:40 +0000)
Review URL: https://codereview.chromium.org/14646025

git-svn-id: http://skia.googlecode.com/svn/trunk@8943 2bbb7eff-a529-9590-31e7-b0007b416f81

src/images/SkImageDecoder.cpp

index 592fffdb3a7789321e28e6276cf14ad5c62be4e7..de0bc14c90e40cd54b49a1985fe535a5c86b0a7b 100644 (file)
@@ -340,28 +340,26 @@ bool SkImageDecoder::DecodeStream(SkStream* stream, SkBitmap* bm,
     return success;
 }
 
-namespace {
-    /**
-     *  This function leaks, but that is okay because it is not intended
-     *  to be called. It is only here so that the linker will include the
-     *  decoders.
-     *  Make sure to keep it in sync with images.gyp, so only the encoders
-     *  which are created on a platform are linked.
-     */
-    void force_linking();
-    void force_linking() {
-        SkASSERT(false);
-        CreateJPEGImageDecoder();
-        CreateWEBPImageDecoder();
-        CreateBMPImageDecoder();
-        CreateICOImageDecoder();
-        CreateWBMPImageDecoder();
-        // Only link GIF and PNG on platforms that build them. See images.gyp
+/**
+ *  This function leaks, but that is okay because it is not intended
+ *  to be called. It is only here so that the linker will include the
+ *  decoders.
+ *  Make sure to keep it in sync with images.gyp, so only the encoders
+ *  which are created on a platform are linked.
+ */
+void force_linking();
+void force_linking() {
+    SkASSERT(false);
+    CreateJPEGImageDecoder();
+    CreateWEBPImageDecoder();
+    CreateBMPImageDecoder();
+    CreateICOImageDecoder();
+    CreateWBMPImageDecoder();
+    // Only link GIF and PNG on platforms that build them. See images.gyp
 #if !defined(SK_BUILD_FOR_MAC) && !defined(SK_BUILD_FOR_WIN) && !defined(SK_BUILD_FOR_NACL)
-        CreateGIFImageDecoder();
+    CreateGIFImageDecoder();
 #endif
 #if !defined(SK_BUILD_FOR_MAC) && !defined(SK_BUILD_FOR_WIN)
-        CreatePNGImageDecoder();
+    CreatePNGImageDecoder();
 #endif
-    }
 }