Creating a simple server-client demo, and the Client will not run when compiled in Debug mode via Visual Studio.
The offending code:
#include <SFML/Graphics.hpp>
sf::Texture tex;
int main()
{
}
Run in a debugger, the program crashes immediately a points to the declaration of
tex as the culprit.
Exception thrown at 0x77E90E72 (ntdll.dll) in Client.exe: 0xC0000005: Access violation writing location 0x00000004.
This only happens when compiled in debug mode. If I remove the declaration of tex, it compiles and runs with no issues, so I don't believe I have any linker mismatches, but just in case, here's the call stack Visual Studio reports:
I have no idea what's causing this so called access violation. It's only now that it's causing this issue, where yesterday, and a month ago, all was well. The accompanying server project has a few variables in the global scope of main.cpp and it compiles and runs in both debug and release with no issues.
save me.