[Diego Biurrun <diego at biurrun.de>] [PATCH] MPlayer changes to libdvdcss

Joey Parrish joey at nicewarrior.org
Tue Jul 19 19:30:17 CEST 2005


On Tue, Jul 05, 2005 at 12:59:45AM +0200, Christophe Massiot wrote:
> >-#if defined( HAVE_STDINT_H )
> >-#   include <stdint.h>
> >-#elif defined( HAVE_INTTYPES_H )
> >-#   include <inttypes.h>
> >-#elif defined( SYS_CYGWIN )
> >-#   include <sys/types.h>
> >-    /* Cygwin only defines half of these... */
> >-    typedef u_int8_t            uint8_t;
> >-    typedef u_int32_t           uint32_t;
> >-#else
> >-    /* Fallback types (very x86-centric, sorry) */
> >-    typedef unsigned char       uint8_t;
> >-    typedef signed char         int8_t;
> >-    typedef unsigned int        uint32_t;
> >-    typedef signed int          int32_t;
> >+#include <inttypes.h>
> >+
> >+#ifdef __CYGWIN__
> >+#define SYS_CYGWIN
> > #endif
> >
> > #if defined( WIN32 )
> 
> I don't know much about that, but wouldn't removing this 
> compatibility stuff break some of our ports ?

SYS_CYGWIN was not defined naturally in the CYGWIN environment.
__CYGWIN__ was defined, so the quick fix was to define SYS_CYGWIN.
Also, CYGWIN does has inttypes.h and all types defined.

> >+        i += sprintf( dvdcss->psz_cachefile + i, "/");
> >
> >-        i += sprintf( dvdcss->psz_cachefile + i, "/%s#%s", psz_title,
> >-                      psz_serial );
> >+//        i += sprintf( dvdcss->psz_cachefile + i, "/%s", psz_data );
> >+	i += sprintf( dvdcss->psz_cachefile + i, "/%s#%s", psz_title, 
> >psz_serial );
> > #if !defined( WIN32 ) || defined( SYS_CYGWIN )
> >         i_ret = mkdir( dvdcss->psz_cachefile, 0755 );
> > #else
> 
> I'm not sure why you removed this ?

Look closely.  Nothing is removed.  A commented and altered version is
added, and the original has it's indentation changed.  Just cosmetics.

--Joey

-- 
"You think without your internal dialog, and I have red socks." --Prem

-- 
This is the libdvdcss-devel mailing-list, see http://developers.videolan.org/
To unsubscribe, go to: http://developers.videolan.org/lists.html



More information about the libdvdcss-devel mailing list