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: get size of object instead of pointer #1103

Merged
merged 1 commit into from
Mar 4, 2024

Conversation

VoltrexKeyva
Copy link
Contributor

The this keyword is evaluated to a pointer to an object of a given type so sizeof(this) returns the size of the pointer instead of the object so use sizeof(*this) instead.

Code change checklist

  • I have ensured that all methods and functions are fully documented using doxygen style comments.
  • My code follows the coding style guide.
  • I tested that my change works before raising the PR.
  • I have ensured that I did not break any existing API calls.
  • I have not built my pull request using AI, a static analysis tool or similar without any human oversight.

The `this` keyword is evaluated to a pointer to an object of a given
type so `sizeof(this)` returns the size of the pointer instead of the
object so use `sizeof(*this)` instead.
@CLAassistant
Copy link

CLAassistant commented Mar 3, 2024

CLA assistant check
All committers have signed the CLA.

Copy link

netlify bot commented Mar 3, 2024

Deploy Preview for dpp-dev ready!

Name Link
🔨 Latest commit ce4570b
🔍 Latest deploy log https://app.netlify.com/sites/dpp-dev/deploys/65e472669896960008195dc2
😎 Deploy Preview https://deploy-preview-1103--dpp-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@github-actions github-actions bot added documentation Improvements or additions to documentation code Improvements or additions to code. labels Mar 3, 2024
Copy link
Member

@Mishura4 Mishura4 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@Mishura4 Mishura4 merged commit 63c00d8 into brainboxdotcc:dev Mar 4, 2024
43 of 44 checks passed
@VoltrexKeyva VoltrexKeyva deleted the get-correct-size branch March 4, 2024 11:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code Improvements or additions to code. documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants