Antoine Pitrou created ARROW-8011: ------------------------------------- Summary: [C++] Some buffers not resized when reading from Parquet Key: ARROW-8011 URL: https://issues.apache.org/jira/browse/ARROW-8011 Project: Apache Arrow Issue Type: Bug Components: C++ Reporter: Antoine Pitrou
This may leak uninitialized data: {code:python} >>> table = pa.Table.from_pydict({"a": pa.array([0, None, None])}) >>> >>> >>> table.column("a").chunk(0).buffers()[1].to_pybytes() >>> >>> b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00' >>> bio = io.BytesIO() >>> >>> >>> pq.write_table(table, bio, use_dictionary=False) >>> >>> >>> bio.seek(0) >>> >>> 0 >>> table = pq.read_table(bio) >>> >>> >>> table.column("a").chunk(0).buffers()[1].to_pybytes() >>> >>> b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00' {code} -- This message was sent by Atlassian Jira (v8.3.4#803005)