A commuter train rammed into the back of a passenger train waiting inside a Madrid tunnel Monday, killing a railway employee and injuring 17 people, officials said.

An official of the state-owned RENFE railway said firefighters pulled two employees from the wrecked locomotive of the commuter train shortly after the 9:10 a.m. accident.One of the employees, a supervisor, was reported dead on arrival at Ramon y Cajal hospital. The second, an engineer, was undergoing emergency surgery there, the official said.

Sixteen passengers were taken to Madrid hospitals for treatment, said the official, who did not give her name.