1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2024-10-06 06:43:22 +02:00

Fixed error handling

This commit is contained in:
Martin Tůma 2016-11-11 21:53:23 +01:00
parent 9cadb8d0a5
commit 215cf03b68

View File

@ -210,7 +210,9 @@ bool IGCParser::loadFile(QFile *file)
_errorLine = 1;
_errorString.clear();
while ((len = file->readLine(line, sizeof(line))) > 0) {
while (!file->atEnd()) {
len = file->readLine(line, sizeof(line));
if (len < 0) {
_errorString = "I/O error";
return false;