...
This rule appears in the C++ Secure Coding Standard as EXP02-CPP. Be aware of the short-circuit behavior of the logical AND and OR operators.
References
Wiki Markup |
---|
\[[CWE|AA. References#CWE]\] [CWE-768|http://cwe.mitre.org/data/definitions/768.html]: Incorrect Short Circuit Evaluation \[[ISO/IEC 9899:1999|AA. References#ISO/IEC 9899-1999]\] Section 6.5.13, "Logical AND operator," and Section 6.5.14, "Logical OR operator" \[[CWE|AA. References#CWE]\] [CWE-768|http://cwe.mitre.org/data/definitions/768.html]: Incorrect Short Circuit Evaluation |
...
EXP01-C. Do not take the size of a pointer to determine the size of the pointed-to type 03. Expressions (EXP)