A 39-year-old man died in SEPTA transit police custody Saturday morning while being driven to a police station, SEPTA and Philadelphia police said.

The man was arrested for shoplifting shortly after 8 a.m. at a Walgreens store at Kensington and Allegheny Avenues in Kensington, according to preliminary information provided by SEPTA spokesperson John Golden. Two SEPTA police officers were driving on Kensington Avenue on patrol — the Allegheny station of the Market-Frankford Line is at the intersection — when they heard yelling and responded, arresting the man.

No force was used during the arrest and there was no struggle, Golden said.

The man, whose name was not released Saturday night, was placed in the back of a police van, also known as a patrol wagon, to be taken to Philadelphia police detectives. The van was driven by two other SEPTA officers, while the arresting officers drove behind.

During the drive, the man lost consciousness, appearing to overdose, Golden said. The SEPTA officers were joined by two Philadelphia police officers after the van stopped outside the police headquarters shared by the 24th and 25th Districts on Whitaker Avenue north of East Erie Avenue. Officers administered the opioid overdose reversal drug naloxone, performed CPR, and used an automated external defibrillator to shock the man’s heart.

Paramedics arrived on the scene and took the man to Temple University Hospital’s Episcopal Campus, where he was pronounced dead at 10:07 a.m.

The SEPTA officers’ body cameras were on, Golden said, and at least one police car’s dashboard camera appeared to have filmed during the incident. That footage was being uploaded late Saturday afternoon for review as part of the investigation, he said.

The Police Department’s East Detectives and homicide units are investigating the death, while SEPTA police are conducting an internal investigation into whether the arresting and transporting officers followed department protocols.

An autopsy is being performed.