LYNN, Mass. (AP) — Authorities say Lynn police fatally shot a man after he pointed a gun at officers when they went to a home to arrest him.

Essex District Attorney Jonathan Blodgett identified the man as 33-year-old Randolph McClain. Blodgett said McClain pointed a gun at an officer, then fled.

Blodgett said McClain approached a car, pointed a gun at a woman in the car and ordered her to get out. He said McClain pointed a gun at officers as they approached the car. Three officers fired their guns, and McClain was hit. He was later pronounced dead.

Police went to the home to arrest McClain on five outstanding warrants for restraining order violations and threats.

The shooting will be investigated by Massachusetts State Police detectives assigned to Blodgett's office.