Protect another "max"

This commit is contained in:
Laurent Rineau 2016-10-28 14:01:26 +02:00
parent fa72bc0f01
commit d5e97c734c
1 changed files with 1 additions and 1 deletions

View File

@ -598,7 +598,7 @@ private:
static tbb::atomic<unsigned int> last_id; static tbb::atomic<unsigned int> last_id;
unsigned int id = ++last_id; unsigned int id = ++last_id;
// Ensure it is > 0 // Ensure it is > 0
return (1 + id%(std::numeric_limits<unsigned int>::max())); return (1 + id%((std::numeric_limits<unsigned int>::max)()));
} }
protected: protected: