Versions Compared

Key

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

...

Code Block
bgColor#ffcccc
char const *filename = "test.txt";
FILE *fptr = fopen(filename, "w");

int c = 97;

while (c &lt;< 123) {
  putc(c++, fptr);
}

...

Code Block
bgColor#ccccff
char const *filename = "test.txt";
FILE *fptr = fopen(filename, "w");

int c = 97;

while (c &lt;< 123) {
  putc(c, fptr);
  c++;
}

...

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

References

Wiki Markup
\[[ISO/IEC 9899-1999:TC2|AA. C References#ISO/IEC 9899-1999TC2]\] Section 7.19.7.5, "The {{getc}} function"; Section 7.19.7.8, "The {{putc}} function"