Memory bug in Vector:copy()