On Wed, 13 May 2026 09:20:05 GMT, Serguei Spitsyn <[email protected]> wrote:

>> Chris Plummer has updated the pull request incrementally with two additional 
>> commits since the last revision:
>> 
>>  - minor comment fix
>>  - more test fixes
>
> test/hotspot/jtreg/vmTestbase/nsk/jdb/kill/kill003/kill003.java line 80:
> 
>> 78: 
>> 79:         // Make sure we stop in jdb when the NPE is thrown or rethrown.
>> 80:         reply = jdb.receiveReplyFor(JdbCommand._catch + "all 
>> java.lang.NullPointerException");
> 
> Q: I wonder if ever there is any need to check what is in the `reply`. The 
> style of this file is that the `reply` is always set but is not checked. Then 
> why do we need to ever set it.

"receiveReplyFor" means issue the specified command and then read the jdb 
output until a prompt is detected. We need to make sure we are back at the 
prompt before issuing the next jdb command. Typically these tests always assign 
to "reply" even if we don't look at the contents.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/31048#discussion_r3235492064

Reply via email to