CodeQL documentation

Inconsistent operation on return value

ID: cpp/inconsistent-call-on-result
Kind: problem
Security severity: 
Severity: warning
Precision: medium
Tags:
   - reliability
   - correctness
   - statistical
   - non-attributable
   - external/cwe/cwe-252
Query suites:
   - cpp-security-and-quality.qls

Click to see the query in the CodeQL repository

If the same operation (e.g. free, delete, close, etc.) is usually performed on the result of a method call, then any instances where it is not performed may indicate misuse of the API and could cause resource leaks or other issues.

Recommendation

Examine the code to determine if the return value is treated correctly in this particular case.

References

  • © GitHub, Inc.
  • Terms
  • Privacy
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy