print a special message when trying to open an FCM reminding user to convert. (finishes SF [ 2011832 ] Opening non movie file crashes FCEUX)
This commit is contained in:
parent
3e983865df
commit
8565ed8f4f
|
@ -1,6 +1,7 @@
|
|||
---version 2.0.2 released---
|
||||
|
||||
11-aug-2008 - zeromus - SF [ 2046985 ] SRAM not wiped on power cycle (during movies)
|
||||
12-aug-2008 - zeromus - print a special message when trying to open an FCM reminding user to convert. (finishes SF [ 2011832 ] Opening non movie file crashes FCEUX)
|
||||
12-aug-2008 - zeromus - SF [ 2046985 ] SRAM not wiped on power cycle (during movies)
|
||||
11-aug-2008 - zeromus - restore IPS patching capability which was lost when archive support was added
|
||||
11-aug-2008 - zeromus - SF [ 2011550 ] Buffer overflow (change vsprintf to vsnprintf)
|
||||
11-aug-2008 - zeromus - SF [ 2047004 ] Moviefilenames without extension don't automatically get fm2
|
||||
|
|
|
@ -461,9 +461,19 @@ static void LoadFM2_binarychunk(MovieData& movieData, std::istream* fp, int size
|
|||
//yuck... another custom text parser.
|
||||
static bool LoadFM2(MovieData& movieData, std::istream* fp, int size, bool stopAfterHeader)
|
||||
{
|
||||
//first, look for an fcm signature
|
||||
char fcmbuf[3];
|
||||
std::ios::pos_type curr = fp->tellg();
|
||||
fp->read(fcmbuf,3);
|
||||
fp->seekg(curr);
|
||||
if(!strncmp(fcmbuf,"FCM",3)) {
|
||||
FCEU_PrintError("FCM File format is no longer supported. Please use Tools > Convert FCM");
|
||||
return false;
|
||||
}
|
||||
|
||||
//movie must start with "version 3"
|
||||
char buf[9];
|
||||
std::ios::pos_type curr = fp->tellg();
|
||||
curr = fp->tellg();
|
||||
fp->read(buf,9);
|
||||
fp->seekg(curr);
|
||||
if(fp->fail()) return false;
|
||||
|
|
Loading…
Reference in New Issue