Fix .wuhb loading when more than .wuhb is on the sd card

This commit is contained in:
Maschell 2022-02-14 20:54:54 +01:00
parent a1ea9531ad
commit fffe25e00b
2 changed files with 2 additions and 0 deletions

View File

@ -19,6 +19,7 @@ int FileHandleWrapper_GetSlot() {
if (!gFileHandleWrapper[i].inUse) {
gFileHandleWrapper[i].inUse = true;
res = i;
break;
}
}
OSMemoryBarrier();

View File

@ -52,6 +52,7 @@ INITIALIZE_PLUGIN() {
memset((void *) &current_launched_title_info, 0, sizeof(current_launched_title_info));
memset((void *) &gLaunchXML, 0, sizeof(gLaunchXML));
memset((void *) &gFileInfos, 0, sizeof(gFileInfos));
memset((void *) &gFileHandleWrapper, 0, sizeof(gFileHandleWrapper));
gHomebrewLaunched = FALSE;
OSInitMutex(&fileWrapperMutex);
OSInitMutex(&fileinfoMutex);