1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-03-24 07:41:54 -07:00

Mvtfinish must make the structure invalid first.

Add comment explaining choice of GCSegClass.

Copied from Perforce
 Change: 182608
 ServerID: perforce.ravenbrook.com
This commit is contained in:
Gareth Rees 2013-06-07 15:39:07 +01:00
parent 4753e1ba3a
commit ccbf5341e8

View file

@ -420,6 +420,8 @@ static void MVTFinish(Pool pool)
arena = PoolArena(pool);
AVERT(Arena, arena);
mvt->sig = SigInvalid;
/* Free the segments in the pool */
ring = PoolSegRing(pool);
RING_FOR(node, ring, nextNode) {
@ -430,8 +432,6 @@ static void MVTFinish(Pool pool)
FreelistFinish(MVTFreelist(mvt));
ABQFinish(arena, MVTABQ(mvt));
CBSFinish(MVTCBS(mvt));
mvt->sig = SigInvalid;
}
@ -1056,6 +1056,8 @@ size_t mps_mvt_free_size(mps_pool_t mps_pool)
static Res MVTSegAlloc(Seg *segReturn, MVT mvt, Size size,
Pool pool, Bool withReservoirPermit)
{
/* Can't use plain old SegClass here because we need to call
* SegBuffer() in MVTFree(). */
Res res = SegAlloc(segReturn, GCSegClassGet(),
MVTSegPref(mvt), size, pool, withReservoirPermit,
argsNone);