I created an a variable for my info logger
and in the constructor of my logger I doCode:std::ofstream FileLog;
And while I can add everything just fine, it doesn't actually outputs the content of FileLog until I do the following in the logger destructor.Code:FileLog.open("log.txt");
How can I make sure that it writes to the log.txt file every time I add something to the log? I want to be able to look at the log's content even if my application crashes.Code:FileLog.close();
Thanks in advance.