RFR: 8224267: JOptionPane message string with 5000+ newlines produces StackOverflowError

Tejesh R tr at openjdk.org
Thu Jul 7 06:31:28 UTC 2022


On Wed, 6 Jul 2022 05:57:00 GMT, Prasanta Sadhukhan <psadhukhan at openjdk.org> wrote:

> BasicOptionPaneUI.addMessageComponents() uses recursion to split message strings at newlines, generating a StackOverflowError when the message string contains an unusually large number of newlines.
> Fixed by catching StackOverflow and ignoring so that application is not stuck.

Marked as reviewed by tr (Author).

-------------

PR: https://git.openjdk.org/jdk/pull/9388



More information about the client-libs-dev mailing list