1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2025-12-26 21:23:21 +00:00

Updated '-info' to not hang if architecture can't be determined

This commit is contained in:
Bryan Roe
2021-08-29 10:39:03 -07:00
parent 55c16811cd
commit 12101c26ab

View File

@@ -242,7 +242,7 @@ char* crashMemory = ILib_POSIX_InstallCrashHandler(argv[0]);
#endif
printf("Agent ARCHID: %d\n", MESH_AGENTID);
char script[] = "console.log('Detected OS: ' + require('os').Name + ' - ' + require('os').arch());process.exit();";
char script[] = "var _tmp = 'Detected OS: ' + require('os').Name; try{_tmp += (' - ' + require('os').arch());}catch(x){}console.log(_tmp);process.exit();";
integratedJavaScript = ILibString_Copy(script, sizeof(script) - 1);
integratedJavaScriptLen = (int)sizeof(script) - 1;
}