Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use panics in handle_assert_failure too when stdio mode is disabled #68

Merged
merged 2 commits into from
Dec 11, 2024

Conversation

bjorn3
Copy link
Collaborator

@bjorn3 bjorn3 commented Dec 11, 2024

When using libbz2-rs-sys as a rust dependency, it is not possible to define bz_internal_error in a way that GNU ld will accept. The definition would come before the use in libbz2-rs-sys and GNU ld will only resolve symbol uses when the defining static library comes after the static library that needs the symbol.

When using as cdylib bz_internal_error will still be called by the panic handler in libbz2-rs-sys-cdylib.

When using libbz2-rs-sys as a rust dependency, it is not possible to
define bz_internal_error in a way that GNU ld will accept. The
definition would come before the use in libbz2-rs-sys and GNU ld will
only resolve symbol uses when the defining static library comes after
the static library that needs the symbol.

When using as cdylib bz_internal_error will still be called by the panic
handler in libbz2-rs-sys-cdylib.
Copy link

codecov bot commented Dec 11, 2024

Codecov Report

Attention: Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
libbz2-rs-sys/src/lib.rs 0.00% 4 Missing ⚠️
Files with missing lines Coverage Δ
libbz2-rs-sys/src/lib.rs 90.16% <0.00%> (+2.86%) ⬆️

@folkertdev folkertdev merged commit d386cd3 into main Dec 11, 2024
19 of 20 checks passed
@folkertdev folkertdev deleted the use_panics branch December 11, 2024 13:52
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