| Wiki Markup |
|---|
If the C99 {{fgets()}} function fails, the contents of the array it was writing to are undefined [indeterminate| BB. Definitions#indeterminate value] \[[ISO/IEC 9899:1999|AA. C References#ISO/IEC 9899-1999]\] (see also [undefined behavior 161| CC. Undefined Behavior#ub_161] of Annex J). Consequently, it is necessary to reset the string to a known value to avoid possible errors on subsequent string manipulation functions. |
...