A man in possession of a loaded gun while sitting in a parked car with three small children and the children’s mother was arrested Tuesday, the Long Beach Police Department announced in a statement on Facebook on Friday.

Long Beach Police Department officers responded to the 800 block of Gladys Avenue regarding reports of a suspicious occupied vehicle that had been parked in the area for two hours, police said.

Officers located the vehicle and began talking to a man who was sitting in the driver’s seat.

“The subject was acting extremely nervous while speaking to the officers about what he was doing in the area, and indicated he did not have identification or a driver’s license,” police said.

Upon further investigation, officers discovered the man had a loaded gun in his pocket, and he attempted to flee. The officers were able to keep him from fleeing and arrested him.

Officers discovered that a woman, who was a friend of the suspect, and her three small children were sitting in the back of the car. They claimed they had no knowledge of the gun, police said, and they were released to go home.

The suspect has been identified as 22-year-old Salvador Orozco of Long Beach. Charges of child endangerment and carrying a loaded firearm in public were filed against him.