-
Enhancement
-
Resolution: Fixed
-
P4
-
21
-
b06
GrowableArrayWithAllocator<>::grow takes an int argument, which is the size to grow from. It uses `next_power_of_2` of that value to determine the size to grow to. Unfortunately, it casts the `int` value to `uint32_t`. As a result, the overflow checks in `next_power_of_2` will be based on the wrong type, leading to a negative new size instead of assertion failure if the size is already large. There are later asserts that will fail for that, but it would be better to remove the offending cast.