pitrou opened a new pull request, #50972: URL: https://github.com/apache/arrow/pull/50972
### Rationale for this change The usage of disparate integer types (`int64_t`, `uint32_t`) makes our checks and computations fragile, especially with C++ adding its own integer promotion rules across arithmetic operations. We have had at least one report (courtesy of Ada Logics and Claude) where a carefully crafted Parquet file can read from an invalid pointer due to arithmetic overflow in the 32-bit domain. ### What changes are included in this PR? Use `int64_t` throughout most internal APIs and code paths when reading Parquet metadata. Other types such as `uint32_t` should only be used where necessary when interacting with third-party libraries such as Thrift C++. ### Are these changes tested? By existing tests, and manually using said hand-crafted Parquet file. ### Are there any user-facing changes? Some APIs taking a `uint32_t*` inout-parameter are deprecated, alternatives taking a `int64_t` value are available. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
