Skip to content

fix: Register linker plugin message callback first#1697

Merged
mati865 merged 3 commits into
wild-linker:mainfrom
mati865:push-yknslmxmrxxk
Mar 16, 2026
Merged

fix: Register linker plugin message callback first#1697
mati865 merged 3 commits into
wild-linker:mainfrom
mati865:push-yknslmxmrxxk

Conversation

@mati865

@mati865 mati865 commented Mar 16, 2026

Copy link
Copy Markdown
Member

Otherwise, linker plugin has no way to indicate invalid arguments.

mati865 added 2 commits March 16, 2026 01:55
Otherwise, linker plugin has no way to indicate invalid arguments.

let mut transfer_vector = Vec::new();

transfer_vector.push(LdPluginTv::fn_ptr2(Tag::Message, message));

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding a comment - something along the lines of "Register message callback first so that the plugin can report problems with subsequent registrations".

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a bit more verbose one. Feel free to tune it as you wish (even with the review suggestion).

@mati865 mati865 changed the title fix: register linker plugin message callback first fix: Register linker plugin message callback first Mar 16, 2026
@mati865 mati865 merged commit 230f37d into wild-linker:main Mar 16, 2026
22 checks passed
@mati865 mati865 deleted the push-yknslmxmrxxk branch March 16, 2026 01:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants