Update tests.

Lazily allocate stats objects on waypoints.
This commit is contained in:
Sandor Dornbush
2010-12-12 20:02:12 -08:00
parent 5047826a74
commit affec6720b
5 changed files with 64 additions and 20 deletions
@@ -427,7 +427,7 @@ public class TrackRecordingService extends Service implements LocationListener {
lastValidLocation = null;
Waypoint waypoint = providerUtils.getFirstWaypoint(recordingTrackId);
if (waypoint != null) {
if (waypoint != null && waypoint.getStatistics() != null) {
currentWaypointId = waypoint.getId();
waypointStatsBuilder = new TripStatisticsBuilder(
waypoint.getStatistics());