diff --git a/edflib.c b/edflib.c index 77fcec3..e0b98eb 100644 --- a/edflib.c +++ b/edflib.c @@ -416,6 +416,8 @@ int edfopen_file_readonly(const char *path, struct edf_hdr_struct *edfhdr, int r free(hdr); hdr = NULL; hdrlist[edfhdr->handle] = NULL; + free(annotationslist[edfhdr->handle]); + annotationslist[edfhdr->handle] = NULL; return -1; } @@ -508,6 +510,10 @@ int edfclose_file(int handle) hdrlist[handle] = NULL; + free(write_annotationslist[handle]); + + write_annotationslist[handle] = NULL; + edf_files_open--; return err; diff --git a/global.h b/global.h index 0600321..dd25b0d 100644 --- a/global.h +++ b/global.h @@ -35,7 +35,7 @@ #define PROGRAM_NAME "DSRemote" -#define PROGRAM_VERSION "0.35_1712271629" +#define PROGRAM_VERSION "0.35_1712291053" #define MAX_PATHLEN 4096