A Humboldt County CHP officer shot and killed a driver early Thursday after being attacked while investigating a crash, the CHP said.

The officer was responding to a 1:35 a.m. report of a single-car crash on Highway 299 near Willow Creek, the CHP said.

Upon arrival, the officer was “violently attacked” by the driver with an undisclosed deadly weapon, the CHP said.

In fear of his life, the officer shot the driver, inflicting fatal injuries. The person died at the scene, the CHP said.

The officer was also injured and taken to a hospital, where he was in stable condition.

The CHP did not release the names of either the officer or the driver. The driver was identified only as a white male.

A countywide shooting investigation team has been assigned to investigate the incident.

You can reach Staff Writer Paul Payne at 568-5312 or paul.payne@pressdemocrat.com. On Twitter @ppayne.