Get Started
- CodeAnt AI
- Control Center
- Pull Request Review
- IDE
- Compliance
- Anti-Patterns
- Code Governance
- Infrastructure Security Database
- Application Security Database
- Apex
- Bash
- C
- Clojure
- Cpp
- Lang
- Correctness
- Memset-removal
- Sizeof-pointer-type
- Sizeof-this
- Security
- Libxml2
- Csharp
- Dockerfile
- Elixir
- Fingerprints
- Generic
- Go
- Html
- Java
- Javascript
- Json
- Kotlin
- Ocaml
- Php
- Problem-based-packs
- Python
- Ruby
- Rust
- Scala
- Solidity
- Swift
- Terraform
- Typescript
- Yaml
Sizeof-this
Sizeof this
Do not use sizeof(this)
to get the number of bytes of the object in memory. It returns the size of the pointer, not the size of the object.
Likelihood: LOW
Confidence: HIGH
CWE:
- CWE-467: Use of sizeof() on a Pointer Type