Antoine Pitrou created ARROW-15615:
--------------------------------------
Summary: [C++] STL allocator doesn't check for multiplication
overflow
Key: ARROW-15615
URL: https://issues.apache.org/jira/browse/ARROW-15615
Project: Apache Arrow
Issue Type: Bug
Components: C++
Reporter: Antoine Pitrou
The MemoryPool-backed STL allocator defined in {{arrow/stl.h}} has the
following code:
{code:c++}
Status s = pool_->Allocate(n * sizeof(T), &data);
{code}
but {{n * sizeof(T)}} might silently overflow and lead to an incorrect
allocation size.
--
This message was sent by Atlassian Jira
(v8.20.1#820001)