Test and fix a bug in vertex array conversion