Repository navigation
Fix HTTP callback dispatch after JNI re-registration - #148
lirenzzzin wants to merge 1 commit into
Conversation
|
CI follow-up: 14 checks passed, including Bookworm x86, x86_64, armhf and arm64 plus the main macOS client variants. I inspected the logs for all five failed checks; none reached the modified client code.
So the red overall workflow status is caused by existing builder/toolchain failures, not a compile failure in this patch. The local RelWithDebInfo build and runtime smoke tests remain green. |
|
Why not just uninstall mod mcpelauncher-updates then? It is not compatible with trinity and never is going to be. |
|
Thanks for clarifying. In my setup, removing mcpelauncher-updates also removes the compatibility patches needed by the newer game version. I understand that Trinity is unsupported. If this scenario is out of scope upstream, I’ll maintain the fix downstream. |
Summary
Root cause
A later JNI library can register native methods with the same HttpClientRequest callback names. That replaces the callback stored in the shared FakeJni descriptor. Normal Minecraft HTTP requests are then delivered to a callback that expects a different sourceCall layout, which eventually tries to lock an invalid mutex and crashes in pthread_mutex_lock.
This keeps the later registration available for calls created by that library, while calls whose first native pointer belongs to libHttpClient.Android.so are sent back to the original libHttpClient callback.
Validation
Related to minecraft-linux/mcpelauncher-manifest#1759.