diff options
Diffstat (limited to 'apt-pkg/policy.cc')
| -rw-r--r-- | apt-pkg/policy.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/apt-pkg/policy.cc b/apt-pkg/policy.cc index ab21cd039..7d11ba898 100644 --- a/apt-pkg/policy.cc +++ b/apt-pkg/policy.cc @@ -314,9 +314,9 @@ static inline bool ExcludePhased(std::string machineID, pkgCache::VerIterator co std::string seedStr = std::string(Ver.SourcePkgName()) + "-" + Ver.SourceVerStr() + "-" + machineID; std::seed_seq seed(seedStr.begin(), seedStr.end()); std::minstd_rand rand(seed); - std::uniform_int_distribution<unsigned int> dist(0, 100); + std::uniform_int_distribution<unsigned int> dist(0, 99); - return dist(rand) > Ver.PhasedUpdatePercentage(); + return dist(rand) >= Ver.PhasedUpdatePercentage(); } APT_PURE signed short pkgPolicy::GetPriority(pkgCache::VerIterator const &Ver, bool ConsiderFiles) { |
