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

fix: properly use base2 (1024, *bibyte) when calculating memory limits #190

Merged
merged 2 commits into from
Jun 29, 2024

Conversation

ArnaudLier
Copy link
Contributor

The Panel gives memory limits in mebibytes (MiB) but Wings considered they were megabytes (MB).

The Panel gives memory limits in mebibytes (MiB) but Wings considered they were megabytes (MB).
@danny6167
Copy link
Member

Looks good and works as intended, but I feel like we could get rid of that const and just hard code those values as it's only 3 locations in one file.

@ArnaudLier
Copy link
Contributor Author

Looks good and works as intended, but I feel like we could get rid of that const and just hard code those values as it's only 3 locations in one file.

It makes the intention a little bit clearer in my opinion but I can inline it if you want.

@danny6167
Copy link
Member

Yeah lets inline to keep consistent with the existing code.
3391d58

Thanks :)

@danny6167 danny6167 removed their assignment Jun 14, 2024
@danny6167
Copy link
Member

Thanks. I've dropped it in the awaiting merge queue

@danny6167 danny6167 added the bug label Jun 14, 2024
@matthewpi matthewpi changed the title fix: incorrect memory limits being given to server containers fix: properly use base2 (1024, *bibyte) when calculating memory limits Jun 29, 2024
@matthewpi matthewpi merged commit 934bf24 into pterodactyl:develop Jun 29, 2024
6 checks passed
dannyhpy pushed a commit to dannyhpy/pterodactyl-wings that referenced this pull request Jul 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: 🧨 Awaiting release
Development

Successfully merging this pull request may close these issues.

3 participants