server deadlock fix