While Luther Mahoney points a gun at Lewis, Mike walks in the room telling Mahoney to put it down. There are several quick edits of Mahoney holding the gun with one hand, then two, then one again.
In several shots the Glock Lewis is holding on Mahoney is shown with the slide locked back, as if it had a failure or the magazine is empty. Instantly the slide is shown forward when Lewis did not have time to drop it or make a sound.
Later on its debated whether or not the shoot was legitimate, but Mahoney had a loaded weapon pointed directly at a policeman. The detectives would have been perfectly justified shooting Mahoney as soon as they walked in the door.