Commit 4d5c816b authored by Sam Hocevar's avatar Sam Hocevar
Browse files

Remove the RPC-II sanity check and only issue a warning. Capable drives are

far too common.
parent badd9197
...@@ -91,13 +91,6 @@ ...@@ -91,13 +91,6 @@
* will use the default value which is "${HOME}/.dvdcss/" under Unix and * will use the default value which is "${HOME}/.dvdcss/" under Unix and
* "C:\Documents and Settings\$USER\Application Data\dvdcss\" under Win32. * "C:\Documents and Settings\$USER\Application Data\dvdcss\" under Win32.
* The special value "off" disables caching. * The special value "off" disables caching.
*
* \li \b DVDCSS_IGNORE_RPC: by default, libdvdcss will refuse to access
* a scrambled disc if the drive reports itself as RPC-II with no
* region set, because such drives are designed to prevent access to
* both the decryption key and the DVD data, rendering any decryption
* method useless. Setting this environment variable to \c 1 will
* bypass this check and try to access the drive anyway.
*/ */
/* /*
...@@ -176,7 +169,6 @@ LIBDVDCSS_EXPORT dvdcss_t dvdcss_open ( char *psz_target ) ...@@ -176,7 +169,6 @@ LIBDVDCSS_EXPORT dvdcss_t dvdcss_open ( char *psz_target )
#if !defined(WIN32) && !defined(SYS_OS2) #if !defined(WIN32) && !defined(SYS_OS2)
char *psz_raw_device = getenv( "DVDCSS_RAW_DEVICE" ); char *psz_raw_device = getenv( "DVDCSS_RAW_DEVICE" );
#endif #endif
char *psz_ignore_rpc = getenv( "DVDCSS_IGNORE_RPC" );
dvdcss_t dvdcss; dvdcss_t dvdcss;
...@@ -202,7 +194,6 @@ LIBDVDCSS_EXPORT dvdcss_t dvdcss_open ( char *psz_target ) ...@@ -202,7 +194,6 @@ LIBDVDCSS_EXPORT dvdcss_t dvdcss_open ( char *psz_target )
dvdcss->psz_cachefile[0] = '\0'; dvdcss->psz_cachefile[0] = '\0';
dvdcss->b_debug = 0; dvdcss->b_debug = 0;
dvdcss->b_errors = 0; dvdcss->b_errors = 0;
dvdcss->b_ignore_rpc = 0;
/* /*
* Find verbosity from DVDCSS_VERBOSE environment variable * Find verbosity from DVDCSS_VERBOSE environment variable
...@@ -372,18 +363,16 @@ LIBDVDCSS_EXPORT dvdcss_t dvdcss_open ( char *psz_target ) ...@@ -372,18 +363,16 @@ LIBDVDCSS_EXPORT dvdcss_t dvdcss_open ( char *psz_target )
dvdcss->b_scrambled = 1; /* Assume the worst */ dvdcss->b_scrambled = 1; /* Assume the worst */
dvdcss->b_ioctls = _dvdcss_use_ioctls( dvdcss ); dvdcss->b_ioctls = _dvdcss_use_ioctls( dvdcss );
dvdcss->b_ignore_rpc = psz_ignore_rpc ? atoi( psz_ignore_rpc ) : 0;
if( dvdcss->b_ioctls ) if( dvdcss->b_ioctls )
{ {
i_ret = _dvdcss_test( dvdcss ); i_ret = _dvdcss_test( dvdcss );
if( i_ret == -3 && !dvdcss->b_ignore_rpc ) if( i_ret == -3 )
{ {
/* Scrambled disk, RPC-II drive, no region set: bail out */ print_debug( dvdcss, "scrambled disc on a region-free RPC-II "
free( dvdcss->psz_device ); "drive: possible failure, but continuing "
free( dvdcss ); "anyway" );
return NULL;
} }
else if( i_ret < 0 ) else if( i_ret < 0 )
{ {
......
...@@ -45,7 +45,6 @@ struct dvdcss_s ...@@ -45,7 +45,6 @@ struct dvdcss_s
css_t css; css_t css;
int b_ioctls; int b_ioctls;
int b_scrambled; int b_scrambled;
int b_ignore_rpc;
dvd_title_t *p_titles; dvd_title_t *p_titles;
/* Key cache directory and pointer to the filename */ /* Key cache directory and pointer to the filename */
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment