fix GCC warning

C:/src/ppsspp/Core/System.cpp: In function 'void DumpFileIfEnabled(const u8*, u32, std::string_view, DumpFileType)':
C:/src/ppsspp/Core/System.cpp:938:29: warning: 'void free(void*)' called on pointer returned from a mismatched allocation function [-Wmismatched-new-delete]
  938 |                         free(path);
      |                         ~~~~^~~~~~
C:/src/ppsspp/Core/System.cpp:924:67: note: returned from 'void* operator new [](std::size_t)'
  924 |                 char *path = new char[strlen(fullPath.c_str()) + 1];
      |
This commit is contained in:
oltolm committed 2025-11-07 22:46:18 +01:00
1 parent 4563d8130a
commit b488c17518
1 file changed
+1 -1
+1 -1
View File
@@ -935,7 +935,7 @@ void DumpFileIfEnabled(const u8 *dataPtr, const u32 length, std::string_view nam
}
}, path);
} else {
free(path);
delete[] path;
}
return;
}