Skip to content
Browse files

Only add to preDeps when it's not in there.

  • Loading branch information...
1 parent 3be9067 commit cc39b66b38657787e99bf6369a77c993cd601c23 @ulion ulion committed
Showing with 3 additions and 5 deletions.
  1. +3 −5 xbmc/addons/AddonInstaller.cpp
View
8 xbmc/addons/AddonInstaller.cpp
@@ -343,13 +343,11 @@ 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)
+ if (dep && std::find(preDeps.begin(), preDeps.end(), dep->ID()) == preDeps.end())
{
- if (std::find(preDeps.begin(), preDeps.end(), dep->ID()) == preDeps.end() &&
- !CheckDependencies(dep, preDeps))
+ if (!CheckDependencies(dep, preDeps))
return false;
- else
- preDeps.push_back(dep->ID());
+ preDeps.push_back(dep->ID());
}
}
return true;

0 comments on commit cc39b66

Please sign in to comment.
Something went wrong with that request. Please try again.