1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-24 22:14:36 +02:00

Survive giving Commander's badge to stacks

Used to SEGFAULT
This commit is contained in:
Vadim Markovtsev 2016-10-30 10:00:25 +01:00
parent 79c85be93f
commit 220e4d2030
2 changed files with 238 additions and 229 deletions

File diff suppressed because it is too large Load Diff

View File

@ -214,6 +214,8 @@ void CArtPlace::clickLeft(tribool down, bool previousState)
bool CArtPlace::askToAssemble(const CArtifactInstance *art, ArtifactPosition slot,
const CGHeroInstance *hero)
{
assert(art != nullptr);
assert(hero != nullptr);
std::vector<const CArtifact *> assemblyPossibilities = art->assemblyPossibilities(hero);
// If the artifact can be assembled, display dialog.