If you use OpenJDK you get an implicit patent grant to run OpenJDK (as it's licensed under the GPL).
If you use any other non-OpenJDK runtime you might still violate some of Oracle's patents, but you don't get any patent grant.
So if you're concerned about patents then using OpenJDK (instead of not using it) would actually be the safer way to go.