[Nestmates] RFR: 8199309: [Nestmates] The new Class nestmate methods should have SecurityManager checks

John Rose john.r.rose at oracle.com
Tue Mar 13 15:42:52 UTC 2018


On Mar 13, 2018, at 4:18 AM, David Holmes <david.holmes at oracle.com> wrote:
> 
> Seems I can't. If I add:
> 
>   Class<?>[] members = getNestMembers0();
> +  assert(members[0] == getNestHost0()); // expected invariant from VM
> 
> then the VM crashes during the build. Seems to hit a recursive attempt to throw an exception from Class.<clinit> then crashes when we exhaust the stack. :(
> 
> I see other asserts in Class so I'm at a loss to understand why mine causes a problem. ??

Darn, another slap from the bootstrap.  Happened to me just the other day with an indy.

A tighter assert, the thing I was really hoping for to deal with the security invariant,
would be:

assert(members.length != 1 || members[0] == this);

— John


More information about the valhalla-dev mailing list