C Books Guide and List
C++ Books Guide and List
Best Java Books

3,749 questions

4,049 answers


10,705 users

What is deadlock?

0 votes
asked Dec 21, 2013 by john Guru (27,140 points)

3 Answers

0 votes
Deadlock is a situation when two threads are waiting on each other to release a resource. Each thread is waiting for a resource which is held by the other waiting thread.
answered Dec 21, 2013 by rajesh Guru (39,140 points)
0 votes
Suppose a process request resources; if the resources are not available at that time the process enters into a wait state. A waiting process may never again change state, because the resources they have requested are held by some other waiting processes. This situation is called deadlock.
answered Dec 30, 2013 by sara Guru (24,570 points)
0 votes
When a thread holds a resource and waits for another resource to be realized by second thread, the second thread holding a resource and waiting for realized by first thread. Both the threads will be waiting in defiantly and they never execute this switching is called as “Deadlock”.

In java there is no mechanism to avoid deadlock situation, it is the responsibility of the programmer to write proper logic to avoid deadlock situation.
answered May 14, 2014 by augustaina Sr Member (4,820 points)

Related questions

0 votes
1 answer 25 views
25 views asked Dec 31, 2013 by sara Guru (24,570 points)
0 votes
1 answer 3,803 views
3,803 views asked Aug 21, 2011 by steve Sr Member (1,460 points)
0 votes
1 answer 91 views
91 views asked May 10, 2014 by sunny Expert (11,410 points)
0 votes
1 answer 73 views
73 views asked May 8, 2014 by rock Expert (14,990 points)
0 votes
1 answer 106 views