diff options
-rw-r--r-- | xbmc/FileSystem/File.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/xbmc/FileSystem/File.cpp b/xbmc/FileSystem/File.cpp index ee48a318e8..1e125a8e76 100644 --- a/xbmc/FileSystem/File.cpp +++ b/xbmc/FileSystem/File.cpp @@ -124,11 +124,19 @@ char* get() { return p; } }; // This *looks* like a copy function, therefor the name "Cache" is misleading -bool CFile::Cache(const CStdString& strFileName, const CStdString& strDest, XFILE::IFileCallback* pCallback, void* pContext) +bool CFile::Cache(const CStdString& strFileName1, const CStdString& strDest, XFILE::IFileCallback* pCallback, void* pContext) { CFile file; CAsyncFileCallback* helper = NULL; + // special case for zips - ignore caching + CStdString strFileName(strFileName1); + if (CUtil::IsInZIP(strFileName)) + { + CURL url(strFileName); + url.SetOptions("?cache=no"); + strFileName = url.Get(); + } if (file.Open(strFileName, READ_TRUNCATED)) { if (file.GetLength() <= 0) |