]> granicus.if.org Git - imagemagick/blobdiff - coders/mpeg.c
(no commit message)
[imagemagick] / coders / mpeg.c
index 1f347685b246809ed274853e915fab4daf836714..0e1add3e35ef7ebccb65c05f85e0a1e0f5cb5efa 100644 (file)
@@ -17,7 +17,7 @@
 %                                 July 1999                                   %
 %                                                                             %
 %                                                                             %
-%  Copyright 1999-2011 ImageMagick Studio LLC, a non-profit organization      %
+%  Copyright 1999-2012 ImageMagick Studio LLC, a non-profit organization      %
 %  dedicated to making software imaging solutions freely available.           %
 %                                                                             %
 %  You may not use this file except in compliance with the License.  You may  %
@@ -60,6 +60,7 @@
 #include "MagickCore/module.h"
 #include "MagickCore/transform.h"
 #include "MagickCore/utility.h"
+#include "MagickCore/utility-private.h"
 \f
 /*
   Forward declarations.
@@ -187,7 +188,7 @@ static Image *ReadMPEGImage(const ImageInfo *image_info,
       image_info->filename);
   assert(exception != (ExceptionInfo *) NULL);
   assert(exception->signature == MagickSignature);
-  image=AcquireImage(image_info);
+  image=AcquireImage(image_info,exception);
   status=OpenBlob(image_info,image,ReadBinaryBlobMode,exception);
   if (status == MagickFalse)
     {
@@ -200,7 +201,7 @@ static Image *ReadMPEGImage(const ImageInfo *image_info,
     Convert MPEG to PAM with delegate.
   */
   read_info=CloneImageInfo(image_info);
-  image=AcquireImage(image_info);
+  image=AcquireImage(image_info,exception);
   (void) InvokeDelegate(read_info,image,"mpeg:decode",(char *) NULL,exception);
   image=DestroyImage(image);
   (void) FormatLocaleString(read_info->filename,MaxTextExtent,"%s.%s",
@@ -417,10 +418,10 @@ static MagickBooleanType CopyDelegateFile(const char *source,
   /*
     Copy source file to destination.
   */
-  destination_file=open(destination,O_WRONLY | O_BINARY | O_CREAT,S_MODE);
+  destination_file=open_utf8(destination,O_WRONLY | O_BINARY | O_CREAT,S_MODE);
   if (destination_file == -1)
     return(MagickFalse);
-  source_file=open(source,O_RDONLY | O_BINARY);
+  source_file=open_utf8(source,O_RDONLY | O_BINARY,0);
   if (source_file == -1)
     {
       (void) close(destination_file);