SLUDGE: fix data file handling with custom encoding setting

The check was inverted - it failed when everything was alright and
succeded on error...
This commit is contained in:
Sebastian Krzyszkowiak 2019-06-17 23:00:34 +02:00 committed by Filippos Karapetis
parent 77db7fcb60
commit 5613caf322

View File

@ -118,7 +118,7 @@ bool CustomSaveHelper::fileToStack(const Common::String &filename, StackHandler
if (_saveEncoding) {
checker = readStringEncoded(fp);
if (checker == UTF8_CHECKER) {
if (checker != UTF8_CHECKER) {
delete fp;
return fatal(LOAD_ERROR "The current file encoding setting does not match the encoding setting used when this file was created:", filename);
}