Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #2489 from Voyager1/fix_addoninstaller_np

fixed: addoninstaller unguarded null pointer after #2475
  • Loading branch information...
commit 3be9067643ca48d94cb9428d7989818760273f8f 2 parents 5cf890c + b545813
ulion ulion authored
Showing with 6 additions and 5 deletions.
  1. +6 −5 xbmc/addons/AddonInstaller.cpp
11 xbmc/addons/AddonInstaller.cpp
View
@@ -343,13 +343,14 @@ bool CAddonInstaller::CheckDependencies(const AddonPtr &addon,
}
// at this point we have our dep, or the dep is optional (and we don't have it) so check that it's OK as well
// TODO: should we assume that installed deps are OK?
- if (dep &&
- std::find(preDeps.begin(), preDeps.end(), dep->ID()) == preDeps.end() &&
- !CheckDependencies(dep, preDeps))
+ if (dep)
{
- return false;
+ if (std::find(preDeps.begin(), preDeps.end(), dep->ID()) == preDeps.end() &&
+ !CheckDependencies(dep, preDeps))
+ return false;
+ else
+ preDeps.push_back(dep->ID());
}
- preDeps.push_back(dep->ID());
}
return true;
}
Please sign in to comment.
Something went wrong with that request. Please try again.