You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A segment is added in track only for adding points, so it can be ignored if it hasn't points.
Proposed solution.
from: foreach (var trksegType in trkType.trkseg)
to: foreach (var trksegType in trkType.trkseg.Where(seg => seg.trkpt != null))
With a GPX 1.1 you have this error parsing a GPX file:
NullReferenceException
if the file contains an empty trkseg element ()
trkseg can be an empty element: http://www.topografix.com/GPX/1/1/#type_trksegType
(it is a complex element and contains a sequence of [0..*] trkpt elements)
The problem is in Gps\Serialization\Gpx11Serializer.cs
trksegType.trkpt is null if trkseg element doesn't contain any point.
(problem exists in version 0.13 and 0.14)
Alessandro
The text was updated successfully, but these errors were encountered: