diff --git a/mps/code/pool.c b/mps/code/pool.c index bbdacc68616..ce7fe6d4b24 100644 --- a/mps/code/pool.c +++ b/mps/code/pool.c @@ -321,6 +321,7 @@ void PoolFree(Pool pool, Addr old, Size size) AVER(old != NULL); /* The pool methods should check that old is in pool. */ AVER(size > 0); + AVER(AddrIsAligned(old, pool->alignment)); AVER(PoolHasRange(pool, old, AddrAdd(old, size))); (*pool->class->free)(pool, old, size); diff --git a/mps/test/argerr/29.c b/mps/test/argerr/29.c index 27418458aa2..d453b65c61d 100644 --- a/mps/test/argerr/29.c +++ b/mps/test/argerr/29.c @@ -6,8 +6,8 @@ TEST_HEADER link = testlib.o OUTPUT_SPEC assert = true - assertfile P= poolmfs.c - assertcond = + assertfile P= pool.c + assertcond = AddrIsAligned(old, pool->alignment) END_HEADER */