1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

csv: fix empty line error

This commit is contained in:
yuyi
2020-05-09 23:35:03 +08:00
committed by GitHub
parent 3eeef6203e
commit 53989daf9a
2 changed files with 30 additions and 0 deletions

View File

@ -103,6 +103,9 @@ fn (r mut Reader) read_record() ?[]string {
l := r.read_line() or {
return error(err)
}
if l.len <= 0 {
continue
}
line = l
// skip commented lines
if line[0] == r.comment {