From f751cb1e9b1012647d3096070bca655417a6c393 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Wolfgang=20St=C3=B6ggl?= Date: Tue, 30 Jul 2019 11:31:33 +0200 Subject: [PATCH] Update win32-glob.c to current upstream version See commit https://sourceforge.net/p/sox/code/ci/5761ed/ for upstream fix. --- win32/win32-glob.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/win32/win32-glob.c b/win32/win32-glob.c index 74f389d3..58d72231 100644 --- a/win32/win32-glob.c +++ b/win32/win32-glob.c @@ -72,7 +72,7 @@ glob( size_t len; unsigned entries = 0; WIN32_FIND_DATAA finddata; - HANDLE hfindfile = FindFirstFileA(pattern, &finddata); + HANDLE hfindfile; if (!pattern || flags != (flags & GLOB_FLAGS) || unused || !pglob) { @@ -93,6 +93,7 @@ glob( len--; path[len] = 0; + hfindfile = FindFirstFileA(pattern, &finddata); if (hfindfile == INVALID_HANDLE_VALUE) { if (flags & GLOB_NOCHECK) -- 2.47.2