comparison dvdread/libdvdread_changes.diff @ 24056:5b9dcfa2d0f0

Sync local diff with current version.
author diego
date Thu, 16 Aug 2007 07:00:08 +0000
parents 6e218aef8e05
children eb9f3e3723d1
comparison
equal deleted inserted replaced
24055:98ba5d5bfe2d 24056:5b9dcfa2d0f0
54 x = ((((x) & 0xff00) >> 8) | \ 54 x = ((((x) & 0xff00) >> 8) | \
55 (((x) & 0x00ff) << 8)) 55 (((x) & 0x00ff) << 8))
56 56
57 --- dvdread.orig/dvd_reader.c 2007-08-06 13:34:37.000000000 +0200 57 --- dvdread.orig/dvd_reader.c 2007-08-06 13:34:37.000000000 +0200
58 +++ dvdread/dvd_reader.c 2007-08-06 13:35:19.000000000 +0200 58 +++ dvdread/dvd_reader.c 2007-08-06 13:35:19.000000000 +0200
59 @@ -33,18 +37,30 @@ 59 @@ -39,12 +37,24 @@
60 #include <limits.h>
61 #include <dirent.h>
62
63 -#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__bsdi__) || defined(__DARWIN__)
64 +#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__bsdi__) || defined(__DARWIN__) || defined(__DragonFly__)
65 #define SYS_BSD 1
66 #endif
67 60
68 #if defined(__sun) 61 #if defined(__sun)
69 #include <sys/mnttab.h> 62 #include <sys/mnttab.h>
70 +#elif defined(hpux) 63 +#elif defined(hpux)
71 +#include </usr/conf/h/mnttab.h> 64 +#include </usr/conf/h/mnttab.h>
96 -#define DEFAULT_UDF_CACHE_LEVEL 1 89 -#define DEFAULT_UDF_CACHE_LEVEL 1
97 +#define DEFAULT_UDF_CACHE_LEVEL 0 90 +#define DEFAULT_UDF_CACHE_LEVEL 0
98 91
99 struct dvd_reader_s { 92 struct dvd_reader_s {
100 /* Basic information. */ 93 /* Basic information. */
101 @@ -402,6 +418,11 @@ 94 @@ -494,7 +503,7 @@
102 Darwin /dev/rdisk0, it needs to be the raw device
103 BSD/OS /dev/sr0c (if not mounted) or /dev/rsr0c ('c' any letter will do) */
104 static char *bsd_block2char( const char *path )
105 +#if defined(__FreeBSD__)
106 +{
107 + return (char *) strdup( path );
108 +}
109 +#else
110 {
111 char *new_path;
112
113 @@ -416,6 +437,7 @@
114
115 return new_path;
116 }
117 +#endif /* __FreeBSD__ */
118 #endif
119
120
121 @@ -481,7 +503,7 @@
122 char *path_copy; 95 char *path_copy;
123 #if defined(SYS_BSD) 96 #if defined(SYS_BSD)
124 struct fstab* fe; 97 struct fstab* fe;
125 -#elif defined(__sun) || defined(__linux__) 98 -#elif defined(__sun) || defined(__linux__)
126 +#elif defined(__sun) || defined(__linux__) || defined(__CYGWIN__) 99 +#elif defined(__sun) || defined(__linux__) || defined(__CYGWIN__)
127 FILE *mntfile; 100 FILE *mntfile;
128 #endif 101 #endif
129 102
130 @@ -585,7 +607,7 @@ 103 @@ -598,7 +607,7 @@
131 } 104 }
132 fclose( mntfile ); 105 fclose( mntfile );
133 } 106 }
134 -#elif defined(__linux__) 107 -#elif defined(__linux__)
135 +#elif defined(__linux__) || defined(__CYGWIN__) 108 +#elif defined(__linux__) || defined(__CYGWIN__)
136 mntfile = fopen( MOUNTED, "r" ); 109 mntfile = fopen( MOUNTED, "r" );
137 if( mntfile ) { 110 if( mntfile ) {
138 struct mntent *me; 111 struct mntent *me;
139 @@ -610,6 +632,9 @@ 112 @@ -623,6 +632,9 @@
140 } 113 }
141 fclose( mntfile ); 114 fclose( mntfile );
142 } 115 }
143 +#elif defined(__MINGW32__) 116 +#elif defined(__MINGW32__)
144 + dev_name = strdup(path); 117 + dev_name = strdup(path);
145 + auth_drive = DVDOpenImageFile( path, have_css ); 118 + auth_drive = DVDOpenImageFile( path, have_css );
146 #endif 119 #endif
147 if( !dev_name ) { 120 if( !dev_name ) {
148 if(verbose >= 1) { 121 if(verbose >= 1) {
149 @@ -828,8 +853,8 @@ 122 @@ -841,8 +853,8 @@
150 } 123 }
151 124
152 if( dvd->css_state == 1 /* Need key init */ ) { 125 if( dvd->css_state == 1 /* Need key init */ ) {
153 - initAllCSSKeys( dvd ); 126 - initAllCSSKeys( dvd );
154 - dvd->css_state = 2; 127 - dvd->css_state = 2;