Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Under what circumstances is a deadlock a good thing?

Tags:

deadlock

What is an example of when a deadlock is beneficial?

like image 406
farm ostrich Avatar asked Feb 25 '23 00:02

farm ostrich


2 Answers

If the program you're deadlocking is a virus?

If you want to freeze up a process, I suppose that would be the only time you should do it... lol.

like image 186
TimFoolery Avatar answered Mar 16 '23 22:03

TimFoolery


It's beneficial in that it clearly demonstrates you that your code is buggy and your synchronization methods need to be revised.

like image 31
EboMike Avatar answered Mar 16 '23 20:03

EboMike