Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Changed to Applicability and updated the reference to Java 7

...

Code Block
bgColor#ccccff
for (i = 1; i <= Integer.MAX_VALUE - 2; i += 2) {
  // ...
}

...

Applicability

Testing for exact values to terminate a loop may result in infinite loops and denial of service.

...

Rule

...

Severity

...

...

Remediation Cost

...

Priority

...

Level

...

MSC54-JG

...

low

...

unlikely

...

low

...

P3

...

L3

Related Guidelines

...

CERT C Secure Coding Standard

...

Bibliography

 

...