Two men were arrested Friday after one attempted to shoot at Stockton Police officers during a slow speed pursuit, police said.

Police say an attempt to stop a vehicle for a traffic violation led to a brief slow speed pursuit, during which the driver attempted to shoot at officers but dropped the gun out of the window.

The pursuit ended when the suspect's vehicle collided with a parked trailer near the intersection of Navajo and Bonanza Drive. Police said a loaded handgun was found during a search of the vehicle.

Officers arrested 23-year-old David Diaz and charged him with resisting an executive officer by means of threat or violence and attempted homicide, in addition to gun and traffic charges.

The vehicle's passenger, 23-year-old Brian Frank, was arrested for gun charges.