adding deadlock