mirror of
https://github.com/dborth/fceugx.git
synced 2025-01-05 21:38:17 +01:00
bugfixes
This commit is contained in:
parent
fe62042ca8
commit
4edbac1b93
@ -122,7 +122,7 @@ SetupCheats()
|
||||
return;
|
||||
|
||||
char filepath[1024];
|
||||
int offset = 0;
|
||||
size_t offset = 0;
|
||||
|
||||
int device = GCSettings.SaveMethod;
|
||||
|
||||
@ -154,7 +154,7 @@ void OpenGameGenie()
|
||||
return;
|
||||
}
|
||||
|
||||
int romSize = 0;
|
||||
size_t romSize = 0;
|
||||
char * tmpbuffer = (char *) memalign(32, 512 * 1024);
|
||||
if(!tmpbuffer)
|
||||
return;
|
||||
|
@ -32,6 +32,8 @@ bool romLoaded = false;
|
||||
|
||||
int GCMemROM(int size)
|
||||
{
|
||||
bool biosError = false;
|
||||
|
||||
ResetGameLoaded();
|
||||
|
||||
CloseGame();
|
||||
@ -89,7 +91,7 @@ int GCMemROM(int size)
|
||||
// read FDS BIOS into FDSBIOS - should be 8192 bytes
|
||||
if (FDSBIOS[1] == 0)
|
||||
{
|
||||
int biosSize = 0;
|
||||
size_t biosSize = 0;
|
||||
char * tmpbuffer = (char *) memalign(32, 64 * 1024);
|
||||
|
||||
char filepath[1024];
|
||||
@ -105,6 +107,8 @@ int GCMemROM(int size)
|
||||
}
|
||||
else
|
||||
{
|
||||
biosError = true;
|
||||
|
||||
if (biosSize > 0)
|
||||
ErrorPrompt("FDS BIOS file is invalid!");
|
||||
else
|
||||
@ -148,7 +152,8 @@ int GCMemROM(int size)
|
||||
delete GameInfo;
|
||||
GameInfo = 0;
|
||||
|
||||
ErrorPrompt("Invalid game file!");
|
||||
if(!biosError)
|
||||
ErrorPrompt("Invalid game file!");
|
||||
romLoaded = false;
|
||||
return 0;
|
||||
}
|
||||
|
@ -267,14 +267,14 @@ bool MakeFilePath(char filepath[], int type, char * filename, int filenum)
|
||||
}
|
||||
else
|
||||
{
|
||||
if(GCSettings.SaveMethod == DEVICE_AUTO)
|
||||
GCSettings.SaveMethod = autoSaveMethod(SILENT);
|
||||
|
||||
if(GCSettings.SaveMethod == DEVICE_AUTO)
|
||||
return false;
|
||||
|
||||
switch(type)
|
||||
{
|
||||
if(GCSettings.SaveMethod == DEVICE_AUTO)
|
||||
GCSettings.SaveMethod = autoSaveMethod(SILENT);
|
||||
|
||||
if(GCSettings.SaveMethod == DEVICE_AUTO)
|
||||
return false;
|
||||
|
||||
case FILE_RAM:
|
||||
case FILE_STATE:
|
||||
sprintf(folder, GCSettings.SaveFolder);
|
||||
|
Loading…
Reference in New Issue
Block a user