9 May
2007
9 May
'07
5:27 a.m.
Eric Pouech <eric.pouech(a)wanadoo.fr> writes:
+static struct assembly* add_assembly(struct actctx* actctx, enum assembly_type at) +{ + struct assembly* assembly; + + if (!actctx->num_assemblies) + actctx->assemblies = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(struct assembly)); + else + actctx->assemblies = HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, + actctx->assemblies, + (actctx->num_assemblies + 1) * sizeof(struct assembly));
Growable arrays should be grown by a multiple of the current size. -- Alexandre Julliard julliard(a)winehq.org