Skip to content

Commit

Permalink
Limit aircraft-relative CPR to 50km.
Browse files Browse the repository at this point in the history
  • Loading branch information
mutability committed Aug 26, 2016
1 parent 568e843 commit 43906f9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions track.c
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,8 @@ static int doLocalCPR(struct aircraft *a, struct modesMessage *mm, uint64_t now,

if (a->pos_nuc < *nuc)
*nuc = a->pos_nuc;

range_limit = 50e3;
} else if (!surface && (Modes.bUserFlags & MODES_USER_LATLON_VALID)) {
reflat = Modes.fUserLat;
reflon = Modes.fUserLon;
Expand Down

0 comments on commit 43906f9

Please sign in to comment.