8000
You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
unzOpen2_64() when it fails keeps file handle open #461
Using unzOpen2_64() with fill_win32_filefunc64() on a file that is not a Zip file causes the file to stay opened. Another process cannot delete the file. The problem is likely with fill_win32_filefunc64().
The issue is on Windows 10.
zlib_filefunc64_def ffunc;
fill_win32_filefunc64(&ffunc);
auto uzf = unzOpen2_64(path.c_str(), &ffunc);
if (uzf == nullptr) {
return false; // The file handle to path is still open!
}
Okay, done.
From: Nathan Moinvaziri <notifications@github.com>
Reply-To: nmoinvaz/minizip <reply@reply.github.com>
Date: Friday, April 3, 2020 at 1:28 PM
To: nmoinvaz/minizip <minizip@noreply.github.com>
Cc: "jim@scratchpaper.com" <jim@scratchpaper.com>, Author <author@noreply.github.com>
Subject: Re: [nmoinvaz/minizip] unzOpen2_64() when it fails keeps file handle open (#461)
Thank you for reporting the issue. The fix looks good, do you want to create a PR?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#461 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AAJQTKSPPCVFRCT4DDZNMUDRKYMCDANCNFSM4L4IIAYA>.
Activity
jimpark commentedon Apr 3, 2020
I think the fix is just a single line of code:
nmoinvaz commentedon Apr 3, 2020
Thank you for reporting the issue. The fix looks good, do you want to create a PR?
Fix zlib-ng#461: unzOpen2_64() when it fails keeps file handle open
jimpark commentedon Apr 3, 2020
Merge pull request #462 from jimpark/dev
nmoinvaz commentedon Apr 4, 2020
Thanks!