mirror of https://github.com/mgba-emu/mgba.git
All: Fix several file handle leaks
This commit is contained in:
parent
ce0adb6c00
commit
82720ca26e
1
CHANGES
1
CHANGES
|
@ -13,6 +13,7 @@ Bugfixes:
|
|||
- Qt: Initialize m_useBios
|
||||
- GBA Serialize: Fix memory corruption bug in GBAExtdataSerialize
|
||||
- GBA Serialize: Fix loading savegames from savestates
|
||||
- All: Fix several file handle leaks
|
||||
Misc:
|
||||
- GBA: Slightly optimize GBAProcessEvents
|
||||
- Qt: Add preset for DualShock 4
|
||||
|
|
|
@ -123,6 +123,7 @@ void GBAUnloadROM(struct GBA* gba) {
|
|||
#ifndef _3DS
|
||||
gba->romVf->unmap(gba->romVf, gba->pristineRom, gba->pristineRomSize);
|
||||
#endif
|
||||
gba->romVf->close(gba->romVf);
|
||||
gba->pristineRom = 0;
|
||||
gba->romVf = 0;
|
||||
}
|
||||
|
|
|
@ -867,6 +867,7 @@ bool GBAGLES2ShaderLoad(struct VideoShader* shader, struct VDir* dir) {
|
|||
}
|
||||
}
|
||||
}
|
||||
manifest->close(manifest);
|
||||
ConfigurationDeinit(&description);
|
||||
return success;
|
||||
}
|
||||
|
|
|
@ -151,7 +151,9 @@ bool ConfigurationRead(struct Configuration* configuration, const char* path) {
|
|||
if (!vf) {
|
||||
return false;
|
||||
}
|
||||
return ConfigurationReadVFile(configuration, vf);
|
||||
bool res = ConfigurationReadVFile(configuration, vf);
|
||||
vf->close(vf);
|
||||
return res;
|
||||
}
|
||||
|
||||
bool ConfigurationReadVFile(struct Configuration* configuration, struct VFile* vf) {
|
||||
|
|
Loading…
Reference in New Issue