Hans Leidekker : mscms: Cast-qual warnings fix.

Alexandre Julliard julliard at wine.codeweavers.com
Thu Oct 5 13:06:21 CDT 2006


Module: wine
Branch: master
Commit: 8af7133dfc70595dca6a486950a5cb3c19bfe8fc
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=8af7133dfc70595dca6a486950a5cb3c19bfe8fc

Author: Hans Leidekker <hans at it.vu.nl>
Date:   Thu Oct  5 15:36:13 2006 +0200

mscms: Cast-qual warnings fix.

---

 dlls/mscms/profile.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/dlls/mscms/profile.c b/dlls/mscms/profile.c
index f28f5ae..0b1b437 100644
--- a/dlls/mscms/profile.c
+++ b/dlls/mscms/profile.c
@@ -615,7 +615,7 @@ BOOL WINAPI EnumColorProfilesA( PCSTR ma
     PROFILEHEADER header;
     WIN32_FIND_DATAA data;
     ENUMTYPEW recordW;
-    WCHAR *fileW = NULL;
+    WCHAR *fileW = NULL, *deviceW = NULL;
     HANDLE find;
 
     TRACE( "( %p, %p, %p, %p, %p )\n", machine, record, buffer, size, number );
@@ -643,8 +643,8 @@ BOOL WINAPI EnumColorProfilesA( PCSTR ma
     memcpy( &recordW, record, sizeof(ENUMTYPEA) );
     if (record->pDeviceName)
     {
-        recordW.pDeviceName = MSCMS_strdupW( record->pDeviceName );
-        if (!recordW.pDeviceName) goto exit;
+        deviceW = MSCMS_strdupW( record->pDeviceName );
+        if (!(recordW.pDeviceName = deviceW)) goto exit;
     }
 
     fileW = MSCMS_strdupW( data.cFileName );
@@ -730,7 +730,7 @@ exit:
     for (i = 0; i < count; i++)
         HeapFree( GetProcessHeap(), 0, profiles[i] );
     HeapFree( GetProcessHeap(), 0, profiles );
-    HeapFree( GetProcessHeap(), 0, (WCHAR *)recordW.pDeviceName );
+    HeapFree( GetProcessHeap(), 0, deviceW );
     HeapFree( GetProcessHeap(), 0, fileW );
     FindClose( find );
 




More information about the wine-cvs mailing list