aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartijn Kaijser <martijn@xbmc.org>2016-10-28 17:04:22 +0200
committerGitHub <noreply@github.com>2016-10-28 17:04:22 +0200
commite92818aecf95c77b04bfb8b4e944e14f5162c75e (patch)
treeb46404eb0e9d82b1107c3dfb79c82ef298017365
parent64d269d12b5ea72c53cb37e806a3a087093364ca (diff)
parent4f95561c54be88cc47735d4d9f3104c75d0ef00b (diff)
Merge pull request #10794 from tamland/fix_addon_install17.0b5-Krypton
[addons] make sure temp dir exists before running CFileOperationJob
-rw-r--r--xbmc/addons/FilesystemInstaller.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/xbmc/addons/FilesystemInstaller.cpp b/xbmc/addons/FilesystemInstaller.cpp
index db3f0ac225..3483727b99 100644
--- a/xbmc/addons/FilesystemInstaller.cpp
+++ b/xbmc/addons/FilesystemInstaller.cpp
@@ -40,6 +40,9 @@ bool CFilesystemInstaller::InstallToFilesystem(const std::string& archive, const
auto newAddonData = URIUtils::AddFileToFolder(m_tempFolder, StringUtils::CreateUUID());
auto oldAddonData = URIUtils::AddFileToFolder(m_tempFolder, StringUtils::CreateUUID());
+ if (!CDirectory::Create(newAddonData))
+ return false;
+
if (!UnpackArchive(archive, newAddonData))
{
CLog::Log(LOGERROR, "Failed to unpack archive '%s' to '%s'", archive.c_str(), newAddonData.c_str());