-
What are the possible reasons for deadlock of |
Beta Was this translation helpful? Give feedback.
Answered by
Darksonn
Nov 8, 2022
Replies: 1 comment
-
The same reasons as any other mutex in any programming language. Any textbook on concurrency will talk about this. The short story is that if you need to lock two mutexes at the same time, you must make sure that you always lock them in the same order. If you don't, then this is very likely to result in a deadlock. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
hawkw
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The same reasons as any other mutex in any programming language. Any textbook on concurrency will talk about this.
The short story is that if you need to lock two mutexes at the same time, you must make sure that you always lock them in the same order. If you don't, then this is very likely to result in a deadlock.