From 25cec35d24a89ecf114961acc52415566f332dea Mon Sep 17 00:00:00 2001 From: Salvador Cuñat Date: Sun, 7 May 2017 10:15:59 +0200 Subject: Datatrak import rework: changes of file.c and file.h MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Datatrak import is called from parse_file() in file.c. This function reads the full file to be imported into a memblock structure. It's easier and more secure, to parse this buffer instead of the file itself. These are the necessary changes in function datatrak_import() declaration and call. Signed-off-by: Salvador Cuñat --- core/file.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'core/file.h') diff --git a/core/file.h b/core/file.h index 8c5647ed2..423d471f9 100644 --- a/core/file.h +++ b/core/file.h @@ -9,7 +9,7 @@ struct memblock { extern int try_to_open_cochran(const char *filename, struct memblock *mem); extern int try_to_open_liquivision(const char *filename, struct memblock *mem); -extern void datatrak_import(const char *file, struct dive_table *table); +extern int datatrak_import(struct memblock *mem, struct dive_table *table); extern void ostctools_import(const char *file, struct dive_table *table); #ifdef __cplusplus -- cgit v1.2.3-70-g09d2