From 3213c9609196d722ec09cf9e5cd1b617dde5bbdc Mon Sep 17 00:00:00 2001 From: Stefan Boberg Date: Wed, 29 Sep 2021 22:25:27 +0200 Subject: filesystem: Fixed issue with FindClose potentially closing an invalid handle --- zencore/filesystem.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'zencore/filesystem.cpp') diff --git a/zencore/filesystem.cpp b/zencore/filesystem.cpp index d1b8b7aeb..54ab2ad85 100644 --- a/zencore/filesystem.cpp +++ b/zencore/filesystem.cpp @@ -138,9 +138,9 @@ WipeDirectory(const wchar_t* DirPath) } } } while (FindNextFileW(hFind, &FindData) == TRUE); - } - FindClose(hFind); + FindClose(hFind); + } return true; } -- cgit v1.2.3