My dog Maggie does that sometimes when she's bored. I usually just
get her busy with a toy or send her outside to patrol for squirrels.