From 602b35aeaaebca492e68067af955da43bcca7a70 Mon Sep 17 00:00:00 2001 From: Frode Solheim Date: Fri, 1 Aug 2025 16:43:56 +0200 Subject: [PATCH] zfile: Free the current list item, not the next (+ two minor fixes) --- include/zfile.h | 1 - zfile.cpp | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/include/zfile.h b/include/zfile.h index b7f09691..915c5580 100644 --- a/include/zfile.h +++ b/include/zfile.h @@ -1,4 +1,3 @@ - /* /* * UAE - The Un*x Amiga Emulator * diff --git a/zfile.cpp b/zfile.cpp index f1f96843..661f17d1 100644 --- a/zfile.cpp +++ b/zfile.cpp @@ -138,7 +138,7 @@ static void zcache_close (void) while (zc) { struct zcache *n = zc->next; zcache_free_data (zc); - xfree (n); + xfree(zc); zc = n; } } @@ -1788,7 +1788,7 @@ static struct zfile *zfile_fopen_x (const TCHAR *name, const TCHAR *mode, int ma if (_tcslen (name) == 0) return NULL; - manglefilename(name, path, sizeof(path) / sizeof TCHAR); + manglefilename(name, path, sizeof(path) / sizeof(TCHAR)); l = zfile_fopen_2 (path, mode, mask); if (!l) return 0; -- 2.47.3