mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-11 07:11:39 +00:00
Fix something I fucked up with GRP scanning when I added support for the Megaton addon GRPs.
git-svn-id: https://svn.eduke32.com/eduke32@3661 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
964e16a506
commit
9c7ab93e21
1 changed files with 17 additions and 5 deletions
|
@ -106,7 +106,7 @@ static void FreeGroupsCache(void)
|
|||
|
||||
void RemoveGroup(int32_t crcval)
|
||||
{
|
||||
struct grpfile *grp, *fg;
|
||||
struct grpfile *grp;
|
||||
|
||||
for (grp = foundgrps; grp; grp=grp->next)
|
||||
{
|
||||
|
@ -114,15 +114,27 @@ void RemoveGroup(int32_t crcval)
|
|||
{
|
||||
if (grp == foundgrps)
|
||||
foundgrps = grp->next;
|
||||
else fg->next = grp->next;
|
||||
else
|
||||
{
|
||||
struct grpfile *fg;
|
||||
|
||||
for (fg = foundgrps; fg; fg=fg->next)
|
||||
{
|
||||
if (fg->next == grp)
|
||||
{
|
||||
fg->next = grp->next;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Bfree((char *)grp->name);
|
||||
Bfree(grp);
|
||||
|
||||
RemoveGroup(crcval);
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
fg = grp;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -242,7 +254,7 @@ int32_t ScanGroups(void)
|
|||
int32_t i;
|
||||
|
||||
for (i = 0; i<NUMGRPFILES; i++) if (grp->crcval == grpfiles[i].crcval) break;
|
||||
if (i == NUMGRPFILES) continue; // unrecognised grp file
|
||||
if (i == NUMGRPFILES) { grp=grp->next; continue; } // unrecognised grp file
|
||||
|
||||
if (grpfiles[i].dependency)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue