Closed elfring closed 7 years ago
Sure. If you check for fputs, errors you also need to check errors by printf, etc. Perhaps just check stdout for error before exiting?
I suggest to avoid ignorance of return values a bit more. How do you think about to improve static source code analysis also for your software?
Regarding the ignorance of return values, you have to balance the probability of errors against the affect on code readability. That's why I suggest a single check at the end of the program.
Regarding static code analysis, yes it should be a part.
Sorry, no.
Would you like to add more error handling for return values from functions like the following?