ImportGen2Map: Fix imports of malformed maps.

Fixes #21126
This commit is contained in:
Jakub Vesely
2023-10-23 19:32:13 +02:00
committed by Gustas
parent d1797a021f
commit 91802e6f10
3 changed files with 54 additions and 15 deletions

View File

@@ -44,7 +44,12 @@ namespace OpenRA.Mods.Common.FileFormats
{
case ';': break;
case '[': currentSection = ProcessSection(line); break;
default: ProcessEntry(line, currentSection); break;
default:
// Skip everything before the first section
if (currentSection != null)
ProcessEntry(line, currentSection);
break;
}
}
}