mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-14 00:28:42 +00:00
Sane failure for rides longer than a week, which usually happen because
someone sets the date on their PT and doesn't reset the device before going for a ride. This fix will keep GC working until the user splits the ride (and until we add a ride-splitting function).
This commit is contained in:
@@ -118,6 +118,10 @@ update_cpi_file(const cpi_file_info *info, QProgressDialog *progress,
|
||||
assert(out);
|
||||
|
||||
int total_secs = (int) ceil(data.points.back().secs);
|
||||
if (total_secs > 7*24*60*60) {
|
||||
fclose(out);
|
||||
return;
|
||||
}
|
||||
double *bests = (double*) calloc(total_secs + 1, sizeof(double));
|
||||
|
||||
bool canceled = false;
|
||||
|
||||
Reference in New Issue
Block a user