In case there is no pit initialize the output variables DW and DL

git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@1259 30fe4595-0a0c-4342-8851-515496e4dcbd

Former-commit-id: 88789232cd6ebeb8d5f1b3976922dd2394db265a
Former-commit-id: 1cfca65c0ef7732f4077d4b5702be1b2807d80b7
This commit is contained in:
wdbee 2009-08-08 12:47:58 +00:00
parent 63b3f528f0
commit 733d0dd3dc

View file

@ -712,6 +712,9 @@ RtDistToPit(struct CarElt *car, tTrack *track, tdble *dL, tdble *dW)
tdble pitts;
tdble carts;
// In case there is no pit initialize the output variables
*dL = 99999.0; // Means far far away
*dW = 0.0; // Any side
if (car->_pit == NULL) return 1;
pitpos = &(car->_pit->pos);