I hope you will take her in for a thorough vet checkup that includes a complete blood panel, thyroid testing, a cardiac checkup, evaluation of eyesight, etc. Tell the vet what is happening. There are health conditions that can cause behavioral issues in dogs.
The two incidents you describe took place (1) when she was on what you describe as "her" pillow, and, (2), when she was eating a treat she was given (and perhaps also on what she considered to be "her" bed?) This sounds like guarding behavior, but it's puzzling that it would suddenly develop at her age. Can you think of anything at all that has changed about her environment or routine?
Regardless of the cause (and I have no idea what that could be just from your one post), there have been a couple of incidents, and I think caution around her is warranted, by all family members. I would suggest not trying to pet her or interact with her while she is in a place that you have designated as "hers," like a dog bed, crate, etc. I believe in giving dogs their own space where they know they can rest in peace and quiet, but she should not believe she owns all of the furniture in the house. If that is the case, it needs to be addressed. Likewise, when she is eating, don't try to pet her, even if it's just a treat. Something has changed, we don't know what, but everyone needs to be careful.
This is all JMO. I am not a training or behavioral expert.
Currently part of my treasured family and helping to make life fun and busy:
Hunter, the chocolate Labradeagle (or Beaglador)
Terra, the tall, gorgeous red Doberwoman
Waiting at the Bridge and forever in my heart...... Igor, Max, Savanna, Logan, and Tasha