RFR(XS): 8160119: Utils.tryFindJvmPid sometimes find incorrect pid

David Holmes david.holmes at oracle.com
Fri Jul 1 03:22:06 UTC 2016


Hi Boris,

On 1/07/2016 2:40 AM, Boris Molodenkov wrote:
> Hi All,
>
> Could you please review fix?
>
> Utils.tryFindJvmPid incorrectly determines process id from jcmd output
> if line which contains desired PID is just after line which ends with
> numbers.
> Fixed pattern.
>
> JBS: https://bugs.openjdk.java.net/browse/JDK-8160119
> Webrev: http://cr.openjdk.java.net/~bmoloden/8160119/webrev.00

I'm no regex expert but that revised pattern seems good to me - it 
constrains the pattern to a line at a time, with only starting digits 
allowed.

Can you fix the typo in the comment preceding that line please - follwed.

Also copyright year needs updating.

No need for updated webrev.

Thanks,
David

> Thanks,
> Boris
>


More information about the hotspot-dev mailing list