I am looking for a movie where a man killed someone and hid in the closet of the victims house. When the police arrived he had reculation of whaat happened. When he was on trial his lawyer realized he was insane and want to change his plea but instead he allowed the defense attorney to bagger the suspect and he attacked her in court.