Kamil Ignacak
2016-08-15 17:16:42 UTC
Hello,
I have noticed that there is a number of places in source code that
don't handle VIK_UNITS_DISTANCE_NAUTICAL_MILES value returned by
a_vik_get_units_distance(). In such places a switch statements handles
KILOMETRES and MILES, but not NAUTICAL_MILES. One such example from
viktrwlayer_tracklist.c:428:
switch ( dist_units ) {
case VIK_UNITS_DISTANCE_MILES:
trk_dist = VIK_METERS_TO_MILES(trk_dist);
break;
default:
trk_dist = trk_dist/1000.0;
break;
}
Other places that I've spotted are:
- viktrwlayer_tpwin.c:519
- viktrwlayer_tracklist.c:625
Is it intentional?
Best regards,
Kamil
I have noticed that there is a number of places in source code that
don't handle VIK_UNITS_DISTANCE_NAUTICAL_MILES value returned by
a_vik_get_units_distance(). In such places a switch statements handles
KILOMETRES and MILES, but not NAUTICAL_MILES. One such example from
viktrwlayer_tracklist.c:428:
switch ( dist_units ) {
case VIK_UNITS_DISTANCE_MILES:
trk_dist = VIK_METERS_TO_MILES(trk_dist);
break;
default:
trk_dist = trk_dist/1000.0;
break;
}
Other places that I've spotted are:
- viktrwlayer_tpwin.c:519
- viktrwlayer_tracklist.c:625
Is it intentional?
Best regards,
Kamil