mirror of
https://github.com/tumic0/GPXSee.git
synced 2025-03-13 10:37:45 +01:00
Be more strict when parsing the TXT files
This commit is contained in:
parent
5d1ba90f09
commit
451782ce20
@ -40,14 +40,14 @@ bool TXTParser::parse(QFile *file, QList<TrackData> &tracks,
|
||||
_errorLine = csv.line() - 1;
|
||||
return false;
|
||||
}
|
||||
} else if (entry.size() == 13) {
|
||||
} else {
|
||||
if (!sg) {
|
||||
_errorString = "Missing start marker";
|
||||
_errorLine = csv.line() - 1;
|
||||
return false;
|
||||
}
|
||||
|
||||
if (entry.at(1) == "A") {
|
||||
if (entry.size() == 13 && entry.at(1) == "A") {
|
||||
Coordinates c(coordinates(entry));
|
||||
if (!c.isValid()) {
|
||||
_errorString = "Invalid coordinates";
|
||||
|
Loading…
x
Reference in New Issue
Block a user