Exeption unhandled

Hi guys.I have problem my code wont debug .
V
This is Vector.cpp
1
2
3
4
5
6
7
8
9
10
  Vector Vector::Add(const Vector &v1)
{
	int i;
	Vector v;
	if (v1.dim == this->dim)
		for (i = 0; i < v1.dim; i++)
	v.vector[i] = v1.vector[i] + this->vector[i]; //vector[i] is type of //Point(another class of points with 3 dimensions(x,y,z))
//here is exception unhandled
	return v;
}
I would think that v is empty and thus v.vector[i] is invalid.
Thank you for the answer.
Topic archived. No new replies allowed.