In Safari 5.1.7, the browser sometimes fails to resolve CSS selectors built
from the document element. Try to detect this and fallback to generating a
random ID for the element that we can reference. To avoid unnecessarily
modifying the DOM, we only use this random ID if the normal selector fails.

Update issue 4996
The underlying issue with SafariDriver and sendKeys is fixed, but I still
need to publish a new prebuilt.  Expect this fix to be available in the
2.32.0 release.