Fixed segmentation faults caused by NULL assignments to std::strings
This commit is contained in:
parent
58b69b912a
commit
b460d76698
|
@ -62,3 +62,9 @@ xcuserdata/
|
||||||
*.ipa
|
*.ipa
|
||||||
*.dSYM.zip
|
*.dSYM.zip
|
||||||
*.dSYM
|
*.dSYM
|
||||||
|
|
||||||
|
## Eclipse CDT generated files
|
||||||
|
/.autotools
|
||||||
|
/.cproject
|
||||||
|
/config.log
|
||||||
|
/.project
|
||||||
|
|
|
@ -658,8 +658,16 @@ struct LastRom {
|
||||||
int NDS_LoadROM(const char *filename, const char *physicalName, const char *logicalFilename)
|
int NDS_LoadROM(const char *filename, const char *physicalName, const char *logicalFilename)
|
||||||
{
|
{
|
||||||
lastRom.filename = filename;
|
lastRom.filename = filename;
|
||||||
|
|
||||||
|
if (physicalName != NULL )
|
||||||
|
{
|
||||||
lastRom.physicalName = physicalName;
|
lastRom.physicalName = physicalName;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (logicalFilename != NULL)
|
||||||
|
{
|
||||||
lastRom.logicalFilename = logicalFilename;
|
lastRom.logicalFilename = logicalFilename;
|
||||||
|
}
|
||||||
|
|
||||||
int ret;
|
int ret;
|
||||||
char buf[MAX_PATH];
|
char buf[MAX_PATH];
|
||||||
|
|
Loading…
Reference in New Issue