Merged
Conversation
On ARM64 macOS, va_list is char* (scalar), not an array type like on x86-64 System V ABI (__va_list_tag[1]). The old #ifdef only special-cased MSVC, so on ARM64 Apple the code read va_list* (expecting array decay) but got a char* value — dereferencing it used string content as a pointer, causing a SIGSEGV in strlen via vsprnt. Fix: guard the pointer-indirection path with __x86_64__ instead of !_MSC_VER.
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.
Summary
SELECT get_ui_context_json()crashes IDA on Apple Silicon with a SIGSEGV instrlencalled fromvsprntva_listABI mismatch inUiMessageCapture::on_event()— the code assumed all non-MSVC platforms use array-typeva_list(which decays to a pointer in variadic calls), but on ARM64 macOSva_listischar*(scalar, passed by value)"__IDASQL...") to be used as a pointer → SIGSEGV__x86_64__(the only platform with array-typeva_list) instead of!_MSC_VERTest plan
SELECT get_ui_context_json()— should return JSON instead of crashing