add log file writing

This commit is contained in:
tildearrow 2022-12-18 01:55:21 -05:00
parent d897ac32b0
commit 51ea3cec2a
6 changed files with 142 additions and 1 deletions

View file

@ -416,7 +416,11 @@ int main(int argc, char** argv) {
logI("usage: %s file",argv[0]);
return 1;
}
logI("Furnace version " DIV_VERSION ".");
e.preInit();
if (!fileName.empty()) {
logI("loading module...");
FILE* f=ps_fopen(fileName.c_str(),"rb");
@ -584,6 +588,8 @@ int main(int argc, char** argv) {
logI("stopping engine.");
e.quit();
finishLogFile();
#ifdef _WIN32
if (coResult==S_OK || coResult==S_FALSE) {
CoUninitialize();