harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Geir Magnusson Jr." <g...@pobox.com>
Subject Re: [classlib][security] Compatibility issue for UnresolvedPermission.getUnresolvedCerts()
Date Tue, 09 Jan 2007 14:02:43 GMT

On Jan 9, 2007, at 8:52 AM, Tim Ellison wrote:

> Geir Magnusson Jr. wrote:
>> I disagree with you all :)
>>
>> The spec is not that ambiguous - it says :
>>
>>   Returns : the signer certificates for the underlying permission
>>   that has not been resolved, or null, if there are no signer
>>   certificates. Returns a new array each time this method is called.
>>
>> Given that it says "Returns a new array each time this method is
>> called", I'd return an empty array, so that if people aren't checking
>> for null (why would you, it says it will return an array....), they
>> don't get an NPE.
>
> There was no claim that the spec is ambiguous, but that it is a
> departure from the behavior of the RI.   In this case it is  
> unlikely to
> break any apps, so it makes sense to follow the spec and declare it a
> bug in the RI.

But I thought you said

"returns null on Harmony, as required by the spec."

The spec could be read to require that you return an empty array,  
rather than null.

geir


Mime
View raw message