Skip to content

Commit

Permalink
Fix issue preventing usage of the 5th and 6th letter of the grid square.
Browse files Browse the repository at this point in the history
  • Loading branch information
tmiw committed Jan 12, 2024
1 parent 21fedeb commit 71e6c0d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/freedv_reporter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -901,7 +901,7 @@ void FreeDVReporterDialog::calculateLatLonFromGridSquare_(wxString gridSquare, d
// If grid square is 6 or more letters, THEN use the next two.
// Otherwise, optional.
wxString optionalSegment = gridSquare.Mid(4, 2);
wxRegEx allLetters(_("^[a-z]{2}$"));
wxRegEx allLetters(_("^[A-Z]{2}$"));
if (gridSquare.Length() >= 6 && allLetters.Matches(optionalSegment))
{
lon += ((char)gridSquare.GetChar(4) - charA) * 5.0 / 60;
Expand Down

0 comments on commit 71e6c0d

Please sign in to comment.