forked from rosebudai/OpenRCT2-Web
Add architecture info to crash dump file name
This commit is contained in:
1 parent
3df88895f7
commit
ead79360c8
1 file changed
+4
-1
@@ -44,6 +44,9 @@ extern "C" {
|
||||
const wchar_t *_wszCommitSha1Short = WSZ("");
|
||||
#endif
|
||||
|
||||
// OPENRCT2_ARCHITECTURE is required to be defined in version.h
|
||||
const wchar_t *_wszArchitecture = WSZ(OPENRCT2_ARCHITECTURE);
|
||||
|
||||
static bool OnCrash(const wchar_t * dumpPath,
|
||||
const wchar_t * miniDumpId,
|
||||
void * context,
|
||||
@@ -70,7 +73,7 @@ static bool OnCrash(const wchar_t * dumpPath,
|
||||
|
||||
// Try to rename the files
|
||||
wchar_t dumpFilePathNew[MAX_PATH];
|
||||
swprintf_s(dumpFilePathNew, sizeof(dumpFilePathNew), L"%s%s(%s).dmp", dumpPath, miniDumpId, _wszCommitSha1Short);
|
||||
swprintf_s(dumpFilePathNew, sizeof(dumpFilePathNew), L"%s%s(%s_%s).dmp", dumpPath, miniDumpId, _wszCommitSha1Short, _wszArchitecture);
|
||||
if (_wrename(dumpFilePath, dumpFilePathNew) == 0)
|
||||
{
|
||||
std::wcscpy(dumpFilePath, dumpFilePathNew);
|
||||
|
||||
Reference in new issue
Block a user