RFR(XS) 8170981: Possible access to char array with negative index
Lindenmaier, Goetz
goetz.lindenmaier at sap.com
Tue Dec 13 08:13:52 UTC 2016
Hi Lutz,
your change looks good, and I agree with Rachel that this is even better.
Best regards,
Goetz.
> -----Original Message-----
> From: hotspot-runtime-dev [mailto:hotspot-runtime-dev-
> bounces at openjdk.java.net] On Behalf Of Schmidt, Lutz
> Sent: Dienstag, 13. Dezember 2016 09:11
> To: Rachel Protacio <rachel.protacio at oracle.com>; hotspot-runtime-
> dev at openjdk.java.net
> Subject: Re: RFR(XS) 8170981: Possible access to char array with negative index
>
> Thank you, Rachel!
>
> Regards, Lutz
>
>
>
>
> On 12.12.16, 20:54, "Rachel Protacio" <rachel.protacio at oracle.com> wrote:
>
> >Looks great!
> >
> >Rachel
> >
> >
> >On 12/12/2016 12:10 PM, Schmidt, Lutz wrote:
> >> Rachel,
> >>
> >>
> >> thanks a lot for the review. An updated webrev (according to my comments
> >> below) can be found here:
> >> http://cr.openjdk.java.net/~simonis/webrevs/2016/8170981.v1
> >>
> >> Regards,
> >> Lutz
> >>
> >>
> >> On 12.12.16, 17:07, "hotspot-runtime-dev on behalf of Rachel Protacio"
> >> <hotspot-runtime-dev-bounces at openjdk.java.net on behalf of
> >> rachel.protacio at oracle.com> wrote:
> >>
> >>> Hi,
> >>>
> >>> I wonder whether it's better to declare
> >>>
> >>> const char* spaces = " ";
> >>>
> >>> and then set nSpaces as strlen(spaces), so it's clear that the spaces
> >>> string will always be consistent with nSpaces?
> >> Good idea, Rachel! I feel uncomfortable with the ³disconnected²
> >> declarations as well. I had to use a non-constant char array because a
> >> Œ\0¹ is stored into it.
> >>
> >> Btw, a ³beautiful² fix would abandon the spaces array altogether and
> >> implement columnar alignment with the help of tty->fill_to(pos). But
> >>that
> >> would be a reengineering effort which might not take the Java9 hurdle.
> >>
> >>> Otherwise, looks good to me.
> >>> Rachel
> >>>
> >>> On 12/12/2016 9:45 AM, Schmidt, Lutz wrote:
> >>>> Hi,
> >>>>
> >>>> may I please ask for reviews and sponsorship for this small fix in
> >>>> command
> >>>> line flag printing?
> >>>>
> >>>> Bug: https://bugs.openjdk.java.net/browse/JDK-8170981
> >>>> webrev: http://cr.openjdk.java.net/~simonis/webrevs/2016/8170981
> >>>>
> >>>> Thank you!
> >>>> Lutz
> >>>>
> >
More information about the hotspot-runtime-dev
mailing list