ext-ds
ext-ds copied to clipboard
Guard against large capacities when allocating
We currently allow allocation via allocate(int $capacity)
, but we don't check for overflow or have a maximum capacity. @nikic also mentioned that we should be using the safe_*
variants when multiplying sizeof
by a variable capacity.
2.0 won't support allocate
so this is now a 1.* issue.
I think we should just remove explicit allocation entirely, in both 1.x and 2.0