Code

fix imagemagick effects for file:// uris
authorbuliabyak <buliabyak@users.sourceforge.net>
Mon, 29 Jun 2009 00:06:57 +0000 (00:06 +0000)
committerbuliabyak <buliabyak@users.sourceforge.net>
Mon, 29 Jun 2009 00:06:57 +0000 (00:06 +0000)
src/extension/internal/bitmap/imagemagick.cpp

index f86d0ec42feeccd2b844ac6635b1b98272084bb1..bfde84e0c4182dda059a564587738b939f1552d7 100644 (file)
@@ -120,7 +120,10 @@ ImageMagickDocCache::readImage(const char *xlink, Magick::Image *image)
                image->read(blob);
        }
        else {
-               image->read(xlink);
+               if (!strncmp(xlink, "file://", 7) && strlen(xlink) > 7)
+                       image->read(xlink + 7);
+               else
+                       image->read(xlink);
        }
 }