Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integer overflow when wager gets payed out #107

Open
CdeJong opened this issue Aug 29, 2023 · 0 comments · May be fixed by #108
Open

Integer overflow when wager gets payed out #107

CdeJong opened this issue Aug 29, 2023 · 0 comments · May be fixed by #108

Comments

@CdeJong
Copy link

CdeJong commented Aug 29, 2023

When using betting amounts higher than half of the (positive) integer limit, the payout amount will overflow to a negative number.

In this example 1,500,000,000.00 was used as wager:
afbeelding

An easy fix would be changing all integers in the plugin to doubles, as this is what vault is using and they have a much higher maximum value. As an extra precaution, I would add a configurable maximum betting amount.

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 a pull request may close this issue.

1 participant