Lol, I was mistakenly sending a single pointer of the FILE to fopen_s, where fopen_s actually expects a double pointer. The linter ignores the type mismatch and proceeds to blast through into generic null pointer warnings.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
When reusing file handles, such as for a REPL, then cppcheck presents what are possibly spurious warnings between these two code sections:
Update:
Lol, I was mistakenly sending a single pointer of the FILE to fopen_s, where fopen_s actually expects a double pointer. The linter ignores the type mismatch and proceeds to blast through into generic null pointer warnings.