]> granicus.if.org Git - imagemagick/commitdiff
(no commit message)
authorcristy <urban-warrior@git.imagemagick.org>
Sat, 25 Feb 2012 14:16:09 +0000 (14:16 +0000)
committercristy <urban-warrior@git.imagemagick.org>
Sat, 25 Feb 2012 14:16:09 +0000 (14:16 +0000)
MagickCore/delegate.c
coders/emf.c

index 75d298728e5f8550ff45a21bdaf5103144e128b3..8655d83843aaf4441cd09e2a60c9a52b053fca50 100644 (file)
@@ -783,16 +783,10 @@ static MagickBooleanType CopyDelegateFile(const char *source,
     *buffer;
 
   /*
-    Return if destination file already exists.
+    Copy source file to destination.
   */
   assert(source != (const char *) NULL);
   assert(destination != (char *) NULL);
-  status=GetPathAttributes(destination,&attributes);
-  if (status != MagickFalse)
-    return(MagickTrue);
-  /*
-    Copy source file to destination.
-  */
   destination_file=open_utf8(destination,O_WRONLY | O_BINARY | O_CREAT,S_MODE);
   if (destination_file == -1)
     return(MagickFalse);
index 9b7e1303e19a21c3c92444fafe0ac3930698578a..1a6c0bbf536629eb923a87affadc6d58e19bf8e9 100644 (file)
  */
 
 #include "MagickCore/studio.h"
-#if defined(MAGICKCORE_WINGDI32_DELEGATE)
+#if defined(MAGICKCORE_WINGDI32_DELEGATE) && defined(__CYGWIN__)
+#  define MAGICKCORE_EMF_DELEGATE
+#endif
+#if defined(MAGICKCORE_EMF_DELEGATE)
 #  if defined(__CYGWIN__)
 #    include <windows.h>
 #  else
 #    include <wingdi.h>
 #  endif
 #endif
-\f
 #include "MagickCore/blob.h"
 #include "MagickCore/blob-private.h"
 #include "MagickCore/cache.h"
@@ -286,7 +288,7 @@ static wchar_t *ConvertUTF8ToUTF16(const unsigned char *source)
   metafile, or an Aldus Placeable metafile and converts it into an enhanced
   metafile.  Width and height are returned in .01mm units.
 */
-#if defined(MAGICKCORE_WINGDI32_DELEGATE)
+#if defined(MAGICKCORE_EMF_DELEGATE)
 static HENHMETAFILE ReadEnhMetaFile(const char *path,ssize_t *width,
   ssize_t *height)
 {
@@ -632,7 +634,7 @@ static Image *ReadEMFImage(const ImageInfo *image_info,
   DeleteObject(hBitmap);
   return(GetFirstImageInList(image));
 }
-#endif /* MAGICKCORE_WINGDI32_DELEGATE */
+#endif /* MAGICKCORE_EMF_DELEGATE */
 \f
 /*
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -663,7 +665,7 @@ ModuleExport size_t RegisterEMFImage(void)
     *entry;
 
   entry=SetMagickInfo("EMF");
-#if defined(MAGICKCORE_WINGDI32_DELEGATE)
+#if defined(MAGICKCORE_EMF_DELEGATE)
   entry->decoder=ReadEMFImage;
 #endif
   entry->description=ConstantString(
@@ -673,7 +675,7 @@ ModuleExport size_t RegisterEMFImage(void)
   entry->module=ConstantString("WMF");
   (void) RegisterMagickInfo(entry);
   entry=SetMagickInfo("WMFWIN32");
-#if defined(MAGICKCORE_WINGDI32_DELEGATE)
+#if defined(MAGICKCORE_EMF_DELEGATE)
   entry->decoder=ReadEMFImage;
 #endif
   entry->description=ConstantString("Windows WIN32 API rendered Meta File");