Fix a bug in detecting CSV file content

NL should be set only if there is an empty line in the input file. That
way the return if no empty line exists (simplistic test for Seabear CSV
file) makes more sense.

Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Miika Turkia 2015-03-30 21:57:12 +03:00 committed by Dirk Hohndel
parent bc44dd8db1
commit 03fc9e3c26

2
file.c
View file

@ -957,9 +957,9 @@ int parse_seabear_csv_file(const char *filename, int timef, int depthf, int temp
while ((ptr = strstr(ptr, "\n\n")) != NULL) {
ptr_old = ptr;
ptr += 1;
NL = "\n";
}
ptr_old += 2;
NL = "\n";
} else
ptr_old += 4;