mirror of
https://github.com/dborth/snes9xgx.git
synced 2025-02-02 21:22:43 +01:00
fix incorrect FAT file loading
This commit is contained in:
parent
830ef92806
commit
1c92d45bc1
@ -234,11 +234,12 @@ LoadBufferFromFAT (char *filepath, bool silent)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*** This is really nice, just load the file and decode it ***/
|
// Just load the file up
|
||||||
while ((read = fread (savebuffer + boffset, 1, 1024, handle)) > 0)
|
fseek(handle, 0, SEEK_END); // go to end of file
|
||||||
{
|
size = ftell(handle); // get filesize
|
||||||
boffset += read;
|
fseek(handle, 0, SEEK_SET); // go to start of file
|
||||||
}
|
fread (sbuffer, 1, size, handle);
|
||||||
|
fclose (handle);
|
||||||
|
|
||||||
fclose (handle);
|
fclose (handle);
|
||||||
|
|
||||||
|
@ -345,8 +345,7 @@ int FileSelector (int method)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case METHOD_SMB:
|
case METHOD_SMB:
|
||||||
ARAM_ROMSIZE =
|
ARAM_ROMSIZE = LoadSMBFile ();
|
||||||
LoadSMBFile ();
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
#include "snapshot.h"
|
#include "snapshot.h"
|
||||||
#include "srtc.h"
|
#include "srtc.h"
|
||||||
|
|
||||||
#include "Snes9xGX.h"
|
#include "snes9xGX.h"
|
||||||
#include "images/saveicon.h"
|
#include "images/saveicon.h"
|
||||||
#include "freeze.h"
|
#include "freeze.h"
|
||||||
#include "filesel.h"
|
#include "filesel.h"
|
||||||
|
@ -25,7 +25,7 @@
|
|||||||
#include "video.h"
|
#include "video.h"
|
||||||
#include "menudraw.h"
|
#include "menudraw.h"
|
||||||
#include "filesel.h"
|
#include "filesel.h"
|
||||||
#include "Snes9xGX.h"
|
#include "snes9xGX.h"
|
||||||
|
|
||||||
bool networkInit = false;
|
bool networkInit = false;
|
||||||
bool networkShareInit = false;
|
bool networkShareInit = false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user