commit | 43314489225afec6964e54a18b449efd8ef06651 | [log] [tgz] |
---|---|---|
author | Nico Huber <nico.huber@secunet.com> | Tue Jan 23 16:19:33 2024 +0100 |
committer | Nico Huber <nico.huber@secunet.com> | Tue Jan 23 16:21:31 2024 +0100 |
tree | cf635292770b44f932160d71f0068c18de57bfe5 | |
parent | f01abce7c05d89259743f753ba2b6c352e3ae7b0 [diff] |
FILO.FS.VFS: Close currently open file before opening new one This is what FILO's current behavior implies (->close_func doesn't get called).
diff --git a/src/filo-fs-vfs.adb b/src/filo-fs-vfs.adb index 02e4c52..31abf65 100644 --- a/src/filo-fs-vfs.adb +++ b/src/filo-fs-vfs.adb
@@ -154,6 +154,10 @@ return; end if; + if Is_Open (State) then + Close (State); + end if; + Str_Cpy (Path (1 .. Path_Len), File_Path); Path (Path_Len + 1 .. Path'Last) := (others => ' ');