The Beowulf poet is oddly silent on the leg issue. The dragon is specified as having wings. Which rather brings us back to Tolkien’s point; if one of the greatest poets in world history failed to mention something, it was probably because they regarded it as insignificant not because they lacked the necessary language or imagination.
We’re interested in D&D, but most of the world doesn’t know who Gary Gygax was, much less care what he thought about anything.
So a dragon can have as many legs as one desires.