C++ with wxWidgets under WIndows - Built binary doesn't fully launch, but sometimes it does
I've been building a project in C++ with wxWidgets for a couple months now and suddenly now, even though the binary .exe file builds, when I launch the exe sometimes (most times) it doesn't show the GUI on screen and terminates but I don't know why. Sometimes it DOES launch and the program works fine. I've tried launching the program: from inside a terminal (power shell or cmd) in VS code (this is how i have been checking the program while developing) by double clicking the exe file from inside a cmd window and i get the same sort of reaction no matter where its run from. i altered cmakelists.txt to turn off building a -mwindows so it will show a console window on launch but there's no segfault or crash message/error. I also have a --console argument that pushes program messages out to std::cout and nothing is shown there when it doesn't launch, except the message i wrote to indicate it's running in --console mode. when the program does launch, everything works fine and messages shown in --console mode as expected. how the hell do you diagnose this? Edit: the source code for this project is here: https://github.com/Cabji/flip-gui/commit/8233b9a7b2825423315dd8e32cf22b1ce7922969 that's the commit that has the launching problem. I'm guessing it is something to do with bad memory allocation, but there's no errors output about this so I don't know?