Update vector.c

Bug fixed