Quote Originally Posted by themolejoel
Any ideas? Hopefully it's something stupid again that's easy to fix!
Like CommonTater, I did not find a problem by inspection. However, I compiled your program with compiler warnings turned on, upon which the problem was obvious from the compiler's warning. This:
Code:
scanf("%lf", ptrCar->price);
should have been:
Code:
scanf("%lf", &ptrCar->price);
Moral of the story: compile with warnings turned on to a sufficiently high level.