Further protect against overlapping string copy by checking if pointers are different... just to be sure it is safe.

This commit is contained in:
harry 2023-01-21 12:11:41 -05:00
parent 26f623f5ea
commit b9385118bd
1 changed files with 4 additions and 1 deletions

View File

@ -807,7 +807,10 @@ static EMUFILE *openRecordingMovie(const char* fname)
FCEU_PrintError("Error opening movie output file: %s", fname);
return NULL;
}
curMovieFilename.assign(fname);
if ( fname != curMovieFilename.c_str() )
{
curMovieFilename.assign(fname);
}
return osRecordingMovie;
}