Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gps parse improvements #156

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Commits on Mar 9, 2024

  1. Prevents invalid sentences from causing crash

    Improves the current implementation of the parse() method to scan
    the entire sentence and count the fields before attempting to read
    the fields.  This prevents accidental invalid pointer accesses when
    parsing invalid sentences with valid checksums.
    
    The new parse implementation also has a smaller compiled size.
    
    Includes a sketch in the "extras" directory (ignored by the Arduino
    IDE according to the library spec) that was used for testing the
    parsing of all sentences known to the parser.
    jpuderer committed Mar 9, 2024
    Configuration menu
    Copy the full SHA
    814a2d6 View commit details
    Browse the repository at this point in the history
  2. Check for null pointer before dereference.

    Implementation of isEmpty() was incorrect since it performed
    a null check after dereferencing the pointer
    jpuderer committed Mar 9, 2024
    Configuration menu
    Copy the full SHA
    3121070 View commit details
    Browse the repository at this point in the history