Trim CSV lines on import
In practice this will sanitize Windows line terminations (discard the carriage return); Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
55582cf5d4
commit
76ce2b095b
@ -514,7 +514,7 @@ void DiveLogImportDialog::loadFileContents(int value, whatChanged triggeredBy)
|
||||
}
|
||||
|
||||
while (rows < 10 && !f.atEnd()) {
|
||||
QString currLine = f.readLine();
|
||||
QString currLine = f.readLine().trimmed();
|
||||
currColumns = currLine.split(separator);
|
||||
fileColumns.append(currColumns);
|
||||
rows += 1;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user