decTypeSize on growObj (#5465)

This commit is contained in:
Yuriy Glukhov
2017-03-15 11:58:34 +02:00
committed by Andreas Rumpf
parent 51cd3bd86f
commit 27c8efda9d

View File

@@ -593,6 +593,7 @@ proc growObj(old: pointer, newsize: int, gch: var GcHeap): pointer =
break
dec(j)
beforeDealloc(gch, ol, "growObj stack trash")
decTypeSize(ol, ol.typ)
rawDealloc(gch.region, ol)
else:
# we split the old refcount in 2 parts. XXX This is still not entirely