Skip to content

[WRAPPER] Fix atexit in the shared library failed to be called#3611

Merged
ptitSeb merged 3 commits intoptitSeb:mainfrom
xiangzhai:atexit
Mar 4, 2026
Merged

[WRAPPER] Fix atexit in the shared library failed to be called#3611
ptitSeb merged 3 commits intoptitSeb:mainfrom
xiangzhai:atexit

Conversation

@xiangzhai
Copy link
Copy Markdown
Contributor

@xiangzhai xiangzhai commented Mar 4, 2026

Hi,

Fix #3467

@yzewei had some good idea for #3474 and I reviewed his rework looks good to me.

Please review the patch.

Thanks,
Leslie Zhai

Co-authored-by: Zewei Yang <yangzewei@loongson.cn>
Comment thread src/core.c Outdated
Comment thread src/core.c
@ptitSeb
Copy link
Copy Markdown
Owner

ptitSeb commented Mar 4, 2026

Does it fix your issue like that?

@xiangzhai xiangzhai requested a review from ptitSeb March 4, 2026 09:29
@xiangzhai
Copy link
Copy Markdown
Contributor Author

Hi,

Does it fix your issue like that?

Yup.

before the patch:

JNI_OnLoad: registering atexit handler vm=0x3a5000 reserved=0x3c6000
In at_exit_handler
JNI_OnLoad: registering atexit handler vm=0x3a5000 reserved=0x3c6000
=> lack of In at_exit_handler

after the patch:

JNI_OnLoad: registering atexit handler vm=0x3a5000 reserved=0x3c6000
In at_exit_handler
JNI_OnLoad: registering atexit handler vm=0x3a5000 reserved=0x3c6000
=> In at_exit_handler

Thanks,
Leslie Zhai

@ptitSeb ptitSeb merged commit 3acd719 into ptitSeb:main Mar 4, 2026
30 checks passed
@xiangzhai
Copy link
Copy Markdown
Contributor Author

Thanks!

@xiangzhai xiangzhai deleted the atexit branch March 4, 2026 11:08
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.

at_exit_handler failed to work when dso_handle is NULL

2 participants