...
Code Block | ||||
---|---|---|---|---|
| ||||
int login;
if (invalid_login())
login = 0;
else
printf("Login is valid\n"); /* Debugging line added here */
login = 1; /* This line always gets executed, regardless of a valid login! */
|
...
Recommendation | Severity | Likelihood | Remediation Cost | Priority | Level |
---|---|---|---|---|---|
EXP19-C | mediumMedium | probableProbable | mediumMedium | P8 | L2 |
Related Guidelines
MISRA C:2012 | Rule 15.6 (required) |
...
[GNU 2010] | Coding Standards, Section 5.3, "Clean Use of C Constructs" | [ISO/IEC 9899:2011] | Section 6.8.4, "Selection Statements" |
...