]> git.saurik.com Git - winterboard.git/commitdiff
iOS <4.x had private ImageIO (thanks forevermac!).
authorJay Freeman (saurik) <saurik@saurik.com>
Thu, 17 Jan 2013 06:24:56 +0000 (06:24 +0000)
committerJay Freeman (saurik) <saurik@saurik.com>
Thu, 17 Jan 2013 06:25:50 +0000 (06:25 +0000)
Library.mm

index 369b1d099c4640b1bea2b5b4bea7d95ab2b4c3d0..716413cff86dece41f4bb9baea7b04daa069ea3e 100644 (file)
@@ -2279,7 +2279,10 @@ MSInitialize {
     }
     // }}}
     // ImageIO {{{
-    if (MSImageRef image = MSGetImageByName("/System/Library/Frameworks/ImageIO.framework/ImageIO")) {
+    MSImageRef imageio = MSGetImageByName("/System/Library/Frameworks/ImageIO.framework/ImageIO");
+    if (imageio == NULL)
+        imageio = MSGetImageByName("/System/Library/PrivateFrameworks/ImageIO.framework/ImageIO");
+    if (MSImageRef image = imageio) {
         void *(*CGImageReadCreateWithFile)(NSString *, int);
         msset(CGImageReadCreateWithFile, image, "_CGImageReadCreateWithFile");
         MSHookFunction(CGImageReadCreateWithFile, MSHake(CGImageReadCreateWithFile));