Open
Conversation
…esolution Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
unrar 7.0 converted all path/name variables from wchar arrays to std::wstring. Update extractchunk.cpp to use the new API: - ArcName, DestFileName, DllDestName are now std::wstring - VolNameToFirstName and ConvertPath have new signatures Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The RARHeaderDataEx struct gained ArcNameEx and FileNameEx pointer fields in unrar 7.0. In rarentry.c the struct was declared on the stack without initialization, leaving these pointers with garbage values. RARReadHeaderEx checks if these pointers are non-NULL before writing through them, so it would follow the garbage pointer and cause a segfault (reproducible in test 004.phpt). Fix by zero-initializing the struct at declaration. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ar 7.1 unrar 7.1 added largepage.cpp and motw.cpp. Add largepage.cpp to the build (its LargePageAlloc class is declared without platform guards and compiled cleanly on Linux with the Windows-only code guarded out). Exclude motw.cpp because MarkOfTheWeb is only declared when PROPAGATE_MOTW is set (Windows-only), so motw.cpp cannot compile on Linux. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
unrar 7.2.4 changed RARReadHeaderEx and ProcessFile to return RarErrorToDll(ErrHandler.GetErrorCode()) on the success path instead of ERAR_SUCCESS. This caused RARX_CRC errors set during header CRC validation (which still allows the header to be read successfully) to propagate as ERAR_BAD_DATA, breaking the entry listing loop for archives with broken header checksums even when allow_broken is set. Non-fatal error codes RARX_SUCCESS, RARX_WARNING, and RARX_CRC should not cause RARReadHeaderEx or ProcessFile to return failure on the success path; callers detect data integrity issues via BrokenHeader or the list result separately. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
These files implement LargePageAlloc and MarkOfTheWeb classes respectively, which were causing 13 unresolved external symbols during the Windows DLL link step. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Fix version
Make it consistent with the rest of the extension, which assumes MBS paths as being in UTF-8.
Add a musl/LLVM Docker build environment for compiling portable Linux binaries that work on both musl and glibc systems, along with a minimal PHP Docker image for testing. Add CI workflows to build and publish these images to ghcr.io. Update test and build scripts to use the new Docker-based environment, and remove SKIPIF guards from tests since the extension is always present and doing otherwise would mask extension loading failures.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.