ref: 167fb80150aaf1869a3d298da87361ea1014bf00
parent: c2db0011fb32e03118e1888369a46b24e548f783
author: Diego Biurrun <[email protected]>
date: Mon Nov 3 08:38:24 EST 2014
Skip determining cache directory name if DVDCSS_CACHE is set to "off".
--- a/src/libdvdcss.c
+++ b/src/libdvdcss.c
@@ -186,6 +186,11 @@
{
char *psz_cache = getenv( "DVDCSS_CACHE" );
+ if( psz_cache && !strcmp( psz_cache, "off" ) )
+ {
+ return NULL;
+ }
+
if( psz_cache == NULL || psz_cache[0] == '\0' )
{
#if defined(_WIN32_IE) && _WIN32_IE >= 0x500
@@ -249,7 +254,7 @@
/* Sanity check psz_cache value. */
if( psz_cache != NULL )
{
- if( psz_cache[0] == '\0' || !strcmp( psz_cache, "off" ) )
+ if( psz_cache[0] == '\0' )
{
return NULL;
}