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

FORTIFY: pthread_mutex_lock called on a destroyed mutex (Android) #1596

Open
ivan-avalos opened this issue Sep 11, 2023 · 2 comments
Open

FORTIFY: pthread_mutex_lock called on a destroyed mutex (Android) #1596

ivan-avalos opened this issue Sep 11, 2023 · 2 comments

Comments

@ivan-avalos
Copy link

ivan-avalos commented Sep 11, 2023

Hey! I'm getting crashes, apparently after initializing and de-initializing multiple times a fragment in the app that contains a map. I'm not getting very useful information from Android Studio, only the following logs before the app crashes:

libc  FORTIFY: pthread_mutex_lock called on a destroyed mutex (0xb400d26bd84434c8)
libc  Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 23219 (External Maply ), pid 22965 (rmap.****)

...

DEBUG  Cmdline: com.****.****
DEBUG  pid: 22965, tid: 23219, name: External Maply  >>> com.****.**** <<<

I tried to make sure I was de-initializing the map correctly, and I wasn't, so I added this:

override fun onDestroyView() {
    super.onDestroyView()
    loader?.shutdown()
    loader = null
}

But no luck. Still getting random crashes. How do I get more debug information?

@sjg-wdw
Copy link
Collaborator

sjg-wdw commented Oct 18, 2023

That's the kind of error you get without a proper shutdown. There should be a teardown or shutdown on the map controller. Make sure that's getting called in the course of tearing down the fragment.

@ivan-avalos
Copy link
Author

That's the kind of error you get without a proper shutdown. There should be a teardown or shutdown on the map controller. Make sure that's getting called in the course of tearing down the fragment.

override fun onDestroyView() {
    super.onDestroyView()
    loader?.shutdown()
    loader = null
}

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

No branches or pull requests

2 participants