Skip to content

Fix index overflow in quickPartition methods. - #17

Open
bkmacy wants to merge 1 commit into
MinesJTK:masterfrom
bkmacy:fix-quickpartition-index-overflow
Open

Fix index overflow in quickPartition methods.#17
bkmacy wants to merge 1 commit into
MinesJTK:masterfrom
bkmacy:fix-quickpartition-index-overflow

Conversation

@bkmacy

@bkmacy bkmacy commented Feb 24, 2021

Copy link
Copy Markdown

When sorting a large array where the length is more than half the maximum integer value, one of the computed indices in quickPartition may overflow, which can lead to a negative array index. This patch fixes the overflow issue using longs to compute the index value.

@codecov

codecov Bot commented Feb 24, 2021

Copy link
Copy Markdown

Welcome to Codecov 🎉

Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.

Thanks for integrating Codecov - We've got you covered ☂️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant