Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[MERGE 15] YSQL: Fix name conflict in aset realloc
Summary: In the master branch, for memory tracking, we added `oldsize` for the block. It overwrites the variable with the same name in the outer scope, defined for the chunk. However, in PG upstream, the `oldsize` in the outer scope is referenced in the inner scope. Because of the naming overwritting, after merging, the reference used becomes incorrect. **Solution** I basically "backport" how the upstream creates the variable for "block old size" and use it is for YB memory tracking. Along with this, it also fixes two potential overflow issues in the existing code. The fixes are needed in the master as well. So a backport to the PG13 branch will be committed later in a separate diff. Original commit: 83c6b6a/D21128 Test Plan: Jenkins: rebase: pg15 Reviewers: neil, mbautin, telgersma Reviewed By: telgersma Subscribers: smishra, yql Differential Revision: https://phabricator.dev.yugabyte.com/D24000
- Loading branch information