Skip to content

Commit

Permalink
Merge pull request #32200 from vespa-engine/toregge/use-consistent-ar…
Browse files Browse the repository at this point in the history
…guments-for-std-max

Use consistent arguments for std::max
  • Loading branch information
baldersheim authored Aug 20, 2024
2 parents a7d86e0 + 381fe48 commit 733e52e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vespalib/src/vespa/vespalib/util/process_memory_stats.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ namespace {
bool
similar(uint64_t lhs, uint64_t rhs, double epsilon)
{
uint64_t maxDiff = std::max(1_Mi, uint64_t(epsilon * (lhs+rhs)/2.0));
uint64_t maxDiff = std::max(uint64_t(1_Mi), uint64_t(epsilon * (lhs+rhs)/2.0));
return (lhs < rhs) ? ((rhs - lhs) <= maxDiff) : ((lhs - rhs) <= maxDiff);
}

Expand Down

0 comments on commit 733e52e

Please sign in to comment.