Removed access to potentially invalid positions on vector.