LA PRYOR, Texas (AP) _ A 10-year-old boy playing with a loaded pistol accidentally shot and killed his 2-year-old niece during a family gathering, police said Thursday.

The girl, Magdalena Cuellar, was pronounced dead on arrival at Uvalde Memorial Hospital after the shooting at 5:15 p.m. Wednesday, Zavala County Deputy Sheriff Gus Marburger said.

''He (the boy) thought it was a gun to play with,'' Marburger said. ''He just found it in the bedroom. ... It's a tragic situation.''

The death is being handled as an accident, Marburger said. The girl's mother, Adelita Cuellar, apparently kept the 9mm automatic handgun for protection, he said.

Investigators said the boy was in a bedroom when the weapon discharged. The girl was struck as she stood in the living room, separated from the bedroom by an open door.

Uvalde County Judge Bill Mitchell, who pronounced the child dead, said she was struck once in her upper left chest.