Prevent stack overflow when a grp configured via .grpinfo erroneously depends on itself. This should also be addressed in the .grpinfo parser, but this fixes it for now.

git-svn-id: https://svn.eduke32.com/eduke32@5273 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2015-07-08 03:34:13 +00:00
parent 26933ecdc2
commit bd427182db

View file

@ -384,7 +384,7 @@ static int32_t G_LoadGrpDependencyChain(grpfile_t const * const grp)
if (!grp)
return -1;
if (grp->type->dependency)
if (grp->type->dependency && grp->type->dependency != grp->type->crcval)
G_LoadGrpDependencyChain(FindGroup(grp->type->dependency));
int32_t const i = G_TryLoadingGrp(grp->filename);