A man has been accused of abandoning his girlfriend's young daughter at a northeast Harris County fast-food restaurant.

Charles Godfrey, 32, has been charged with endangering a child.

Harris County sheriff's deputies said Godfrey left the 2-year-old girl alone at a McDonald's on the Eastex Freeway near West Little York late Monday.

Godfrey went back to the restaurant about an hour after the girl was left, investigators said. He was then arrested.

Detectives said they don't know why Godfrey left the girl at the restaurant.