I’ve done some search without any specific result, so I will answer considering usability principles and software history:
The undo function was already here in the 70’s but was not until the appearance and expansion of graphical interfaces and increasing popularity of desktop computers that it got its icon identity.
In those times the users didn’t use a lot of applications, being the most popular the text processors.
Without a doubt one of the most popular software of that time was Microsoft Word.
Take a look at its icon in 1993 :
This is a common matter with icons (and other software components): they are very unlikely to change over time once they are established and recognizable for most users. This is the same reason why we keep using the QWERTY keyboard instead of one with another layout that allows better performance: Familiarity.
This allows the user to keep using new systems without any pain and allow companies to avoid a difficult question to answer: “Will they got this?”.
The straight arrows are used mainly for navigation and because of its simplicity can be used for many “movement” action, including the undo action, which allows getting back to the previous state of what we are editing.
But it doesn’t work the other way around. Curved arrows are not used that frequently.
If you place a fully rounded undo button in a browser bar it could be easily be misinterpreted as a Refresh button since the icon is almost the same.
So my recommendation in a context where a Refresh action could be possible in the mind of users would be to stay with something rounded but NOT fully rounded, to avoid users confusion. Of course, in specific context this won’t be a problem while the appearance of the Undo icon remains as a clearly curved arrow.