gh-131740: Update PyUnstable_GC_VisitObjects to traverse perm gen (gh-131744)

This commit is contained in:
Donghee Na 2025-03-26 09:45:29 +09:00 committed by GitHub
parent a26a301f8b
commit 7bb41aef4b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 1 deletions

View File

@ -0,0 +1 @@
Update PyUnstable_GC_VisitObjects to traverse perm gen.

View File

@ -2415,7 +2415,10 @@ PyUnstable_GC_VisitObjects(gcvisitobjects_t callback, void *arg)
if (visit_generation(callback, arg, &gcstate->old[0])) {
goto done;
}
visit_generation(callback, arg, &gcstate->old[1]);
if (visit_generation(callback, arg, &gcstate->old[1])) {
goto done;
}
visit_generation(callback, arg, &gcstate->permanent_generation);
done:
gcstate->enabled = origenstate;
}