Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Failing to properly construct or destroy an object leaves its internal state inconsistent, which can result in undefined behavior and accidental information exposure.

Rule

Severity

Likelihood

Remediation Cost

Priority

Level

MEM53-CPP

High

Likely

Medium

P18

L1

Automated Detection

Tool

Version

Checker

Description

   
Helix QAC

Include Page
Helix QAC_V
Helix QAC_V

DF4761, DF4762, DF4766, DF4767


Parasoft C/C++test

Include Page
Parasoft_V
Parasoft_V

CERT_CPP-MEM53-a

Do not invoke malloc/realloc for objects having constructors
Polyspace Bug Finder

Include Page
Polyspace Bug Finder_V
Polyspace Bug Finder_V

CERT C++: MEM53-CPPChecks for objects allocated but not initialized (rule fully covered).
PVS-Studio

Include Page
PVS-Studio_V
PVS-Studio_V

V630V749
 

Related Vulnerabilities

Search for vulnerabilities resulting from the violation of this rule on the CERT website.

Related Guidelines

Bibliography

[ISO/IEC 14882-2014]Subclause 3.8, "Object Lifetime"
Clause 9, "Classes"

...


...

Image Modified Image Modified Image Modified