Moved the generic list-growing function into util.c so that the