This has been randomly occurring ever since I installed leopard. It doesn't happen very often, but lately it's been happening more and more often. I'll try and restart or shutdown OS X and it will hang. After awhile it will give me an error saying that the restart/shutdown was halted by a program not closing (always the last program to close). The problem is that the programs it halts on have already been closed and there is no listing of them on the Activity Monitor or the Force Quit menu. I've tried repairing permissions but it doesn't change anything. The only way to shut down my MBP is to hold down the power button. What can I do to fix this? edit: I' also having some other problems that may be related. 1. I've got a lock icon on the menu bar I use to lock my computer when I'm away from it. Sometimes clicking that lock won't do anything, it won't lock the computer, it just does nothing. 2. Also, I'll close the lid on my MBP, and when I open it back up, the login screen won't always come up. I'm left with a black screen and a pointer. I have to close the lid and open it again to have it pop up.