jayduhon / inferno-os

Automatically exported from code.google.com/p/inferno-os
2 stars 0 forks source link

libinterp/heap.c:/^dtype cleanup #258

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I'm not 100% sure, but looks like there extra 4 bytes allocated by dtype(). It 
probably should be changed in this way:

-  t = malloc(sizeof(Type)+mapsize);
+  t = malloc(sizeof(Type)+mapsize-sizeof(((Type*)0)->map));

Original issue reported on code.google.com by powerman...@gmail.com on 16 Apr 2011 at 12:41

GoogleCodeExporter commented 9 years ago
committed changeset 519:d1acc2a527af

i'd been delaying until I could rely on uchar field[] everywhere, but might as 
well do this meanwhile.

Original comment by Charles....@gmail.com on 3 Oct 2011 at 6:16