7-Zip-zstd
7-Zip-zstd copied to clipboard
Error when extracting zip file
When using context menu extract the message Cannot find archive name is displayed. When 7zip is opened, it can be extracted without issue.
Would be awesome to get a fix, this is the main way I use 7zip.
Having the same issue too.
Also have the issue. Worked fine on v22.01-v1.5.5-R2 & broke after updating to v22.01-v1.5.5-R3.
Downgrade by running the old 7z22.01-zstd-x64.exe
installer from v22.01-v1.5.5-R2 directly over the R3
installation fixed it.
Here's what it does
https://github.com/mcmilk/7-Zip-zstd/assets/7283693/289df801-2127-47a6-9654-24cd76043db7
I am sure the issue is not the version, but the inconsistency after upgrade (library for integration in file explorer didn't update therefore doesn't match new 7z.dll)... Basically same issue than https://github.com/mcmilk/7-Zip-zstd/pull/313#issuecomment-1504914800.
Thus can be closed as duplicate... I have no idea whether and in which cases MSI installer may not correctly upgrade everything, even after reboot. Or whether it is a bug of install-script. I'll take a closer look later.
Hmm... The issue (with not renaming .tmp
by install) may happen here:
https://github.com/mcmilk/7-Zip-zstd/blob/62bfad55c339f7f76b1880a59378245b6dfbbf49/C/Util/7zipInstall/7zipInstall.c#L1560
Just I still don't follow why - since it seems to add the operation to HKLM\System\CurrentControlSet\Control\Session Manager\PendingFileRenameOperations
properly and the reason why it'd fail at start would be only access denied (why?) or some similar circumstances.
How it will be installed? Hopefully as admin or with UAC elevation?
Current algorithm looks like:
- try to open file to write in-place (with original name)
- write file with current name (original or tmp)
- if it failed, try to find unused
.tmp
name (with some hex inside, up to 100 times) and repeat - if it success stop and when that was tmp-file, register pending rename with
MoveFileExW
No idea why it doesn't work, so the only attempt to "repair" I can imagine at the moment would be something like this:
try to rename current non-writable file to .tmp
(if library is used, it is mostly not writable, but normally can be renamed) and then if it is successful, to write the file with original name without a necessity to rename it back with MoveFileExW
later.
And then register pending delete for that tmp-file (also with MoveFileExW
).
In the case MoveFileExW
would fail for some reason, the new DLL has already correct name and possibly only tmp-file remains as a small leak in the 7z-install folder.