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

Hopefully fix the random crashes with threads #30934

Merged
merged 1 commit into from Aug 8, 2019

Conversation

santouits
Copy link
Contributor

@santouits santouits commented Jul 29, 2019

fixes #21685
possibly other random things too

@akien-mga akien-mga added this to the 3.2 milestone Jul 29, 2019
@akien-mga akien-mga requested a review from reduz July 29, 2019 17:48
@bojidar-bg
Copy link
Contributor

Will conflict with #30801, though if it does fix thread-related crashes...

@santouits
Copy link
Contributor Author

Will conflict with #30801, though if it does fix thread-related crashes...

To be honest I don't know if that check I put there helps with the fix, I just thought that it shouldn't be interacting with the debugger if it is a function running in a thread. The example in the issue stopped crashing after I added the lock in object.h, but I left that change too. I will see if it works without that check.

@santouits
Copy link
Contributor Author

Alright it fixes the issue without that code. I removed it and it can be added in another PR, I think without it it will mess the debugger if you are on a breakpoint in the main thread and another thread keeps running.

@akien-mga akien-mga requested review from hpvb and removed request for vnen July 31, 2019 09:41
@akien-mga
Copy link
Member

For the reference, that's also what #28791 implemented (together with a new method).

Let's give this PR a spin (pun intended) :)

@akien-mga akien-mga merged commit 274bac2 into godotengine:master Aug 8, 2019
@akien-mga
Copy link
Member

Thanks!

@akien-mga
Copy link
Member

Cherry-picked for 3.1.2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

OS singleton not thread-safe when launched from the editor
3 participants