mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-31 14:37:59 +00:00
xbmc: add patch to revert pats of 23607e247c0074d88464a39eca643897550cb70
Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
parent
d6215338fb
commit
07481e78a3
@ -0,0 +1,63 @@
|
|||||||
|
From 505b702af7025ad977558e75d25764744c47f5a3 Mon Sep 17 00:00:00 2001
|
||||||
|
From: vdrfan <vdrfan-nospam-@xbmc.org>
|
||||||
|
Date: Wed, 28 Dec 2011 00:31:07 +0100
|
||||||
|
Subject: [PATCH] fixed: reverted File.cpp parts of
|
||||||
|
23607e247c0074d88464a39eca643897550cb70 as they were
|
||||||
|
causing troubles
|
||||||
|
|
||||||
|
---
|
||||||
|
xbmc/filesystem/File.cpp | 14 ++++++++------
|
||||||
|
1 files changed, 8 insertions(+), 6 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/xbmc/filesystem/File.cpp b/xbmc/filesystem/File.cpp
|
||||||
|
index 375226e..ef16255 100644
|
||||||
|
--- a/xbmc/filesystem/File.cpp
|
||||||
|
+++ b/xbmc/filesystem/File.cpp
|
||||||
|
@@ -217,15 +217,16 @@ bool CFile::Open(const CStdString& strFileName, unsigned int flags)
|
||||||
|
try
|
||||||
|
{
|
||||||
|
bool bPathInCache;
|
||||||
|
- CURL url(URIUtils::SubstitutePath(strFileName));
|
||||||
|
- if (url.GetProtocol() == "zip")
|
||||||
|
- url.SetOptions("");
|
||||||
|
- if (!g_directoryCache.FileExists(url.Get(), bPathInCache) )
|
||||||
|
+ CURL url2(strFileName);
|
||||||
|
+ if (url2.GetProtocol() == "zip")
|
||||||
|
+ url2.SetOptions("");
|
||||||
|
+ if (!g_directoryCache.FileExists(url2.Get(), bPathInCache) )
|
||||||
|
{
|
||||||
|
if (bPathInCache)
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
+ CURL url(URIUtils::SubstitutePath(strFileName));
|
||||||
|
if ( (flags & READ_NO_CACHE) == 0 && URIUtils::IsInternetStream(url) && !CUtil::IsPicture(strFileName) )
|
||||||
|
m_flags |= READ_CACHED;
|
||||||
|
|
||||||
|
@@ -343,7 +344,7 @@ bool CFile::OpenForWrite(const CStdString& strFileName, bool bOverWrite)
|
||||||
|
|
||||||
|
bool CFile::Exists(const CStdString& strFileName, bool bUseCache /* = true */)
|
||||||
|
{
|
||||||
|
- CURL url(URIUtils::SubstitutePath(strFileName));
|
||||||
|
+ CURL url;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
@@ -353,12 +354,13 @@ bool CFile::Exists(const CStdString& strFileName, bool bUseCache /* = true */)
|
||||||
|
if (bUseCache)
|
||||||
|
{
|
||||||
|
bool bPathInCache;
|
||||||
|
- if (g_directoryCache.FileExists(url.Get(), bPathInCache) )
|
||||||
|
+ if (g_directoryCache.FileExists(strFileName, bPathInCache) )
|
||||||
|
return true;
|
||||||
|
if (bPathInCache)
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
+ url = URIUtils::SubstitutePath(strFileName);
|
||||||
|
auto_ptr<IFile> pFile(CFileFactory::CreateLoader(url));
|
||||||
|
if (!pFile.get())
|
||||||
|
return false;
|
||||||
|
--
|
||||||
|
1.7.5.4
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user