[MPlayer-cvslog] CVS: main/libmpdvdkit2 device.c, 1.7, 1.8 ioctl.h, 1.4, 1.5

Sascha Sommer CVS syncmail at mplayerhq.hu
Tue Jun 7 15:36:23 CEST 2005


CVS change done by Sascha Sommer CVS

Update of /cvsroot/mplayer/main/libmpdvdkit2
In directory mail:/var2/tmp/cvs-serv4472/libmpdvdkit2

Modified Files:
	device.c ioctl.h 
Log Message:
mingw gcc 4.1 support patch by Gianluigi Tiesi <mplayer at netfarm.it>

Index: device.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdvdkit2/device.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- device.c	1 Mar 2005 06:41:41 -0000	1.7
+++ device.c	7 Jun 2005 13:36:21 -0000	1.8
@@ -273,14 +273,14 @@
      * won't send back the right result).
      * (See Microsoft Q241374: Read and Write Access Required for SCSI
      * Pass Through Requests) */
-    (HANDLE) dvdcss->i_fd =
+    dvdcss->i_fd = (int)
                 CreateFile( psz_dvd, GENERIC_READ | GENERIC_WRITE,
                             FILE_SHARE_READ | FILE_SHARE_WRITE,
                             NULL, OPEN_EXISTING,
                             FILE_FLAG_RANDOM_ACCESS, NULL );
 
     if( (HANDLE) dvdcss->i_fd == INVALID_HANDLE_VALUE )
-        (HANDLE) dvdcss->i_fd =
+        dvdcss->i_fd = (int)
                     CreateFile( psz_dvd, GENERIC_READ, FILE_SHARE_READ,
                                 NULL, OPEN_EXISTING,
                                 FILE_FLAG_RANDOM_ACCESS, NULL );
@@ -302,8 +302,8 @@
     DWORD dwSupportInfo;
     struct w32_aspidev *fd;
     int i, j, i_hostadapters;
-    long (*lpGetSupport)( void );
-    long (*lpSendCommand)( void* );
+    GETASPI32SUPPORTINFO lpGetSupport;
+    SENDASPI32COMMAND lpSendCommand;
     char c_drive = psz_device[0];
 
     /* load aspi and init w32_aspidev structure */
@@ -314,8 +314,8 @@
         return -1;
     }
 
-    (FARPROC) lpGetSupport = GetProcAddress( hASPI, "GetASPI32SupportInfo" );
-    (FARPROC) lpSendCommand = GetProcAddress( hASPI, "SendASPI32Command" );
+    lpGetSupport = (GETASPI32SUPPORTINFO) GetProcAddress( hASPI, "GetASPI32SupportInfo" );
+    lpSendCommand = (SENDASPI32COMMAND) GetProcAddress( hASPI, "SendASPI32Command" );
 
     if(lpGetSupport == NULL || lpSendCommand == NULL )
     {

Index: ioctl.h
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdvdkit2/ioctl.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- ioctl.h	1 Mar 2005 06:07:40 -0000	1.4
+++ ioctl.h	7 Jun 2005 13:36:21 -0000	1.5
@@ -318,6 +318,9 @@
  * win32 aspi specific
  *****************************************************************************/
 
+typedef WINAPI DWORD (*GETASPI32SUPPORTINFO)(VOID);
+typedef WINAPI DWORD (*SENDASPI32COMMAND)(LPVOID);
+
 #define WIN2K               ( GetVersion() < 0x80000000 )
 #define ASPI_HAID           0
 #define ASPI_TARGET         0
@@ -339,7 +342,7 @@
     long  hASPI;
     short i_sid;
     int   i_blocks;
-    long  (*lpSendCommand)( void* );
+    SENDASPI32COMMAND lpSendCommand;
 };
 
 #pragma pack(1)




More information about the MPlayer-cvslog mailing list