RFR: JDK-8035631 - JNI exception pending in jdk/src/windows/native/java/net/NetworkInterface_winXP.c

Michael McMahon michael.x.mcmahon at oracle.com
Fri Mar 21 16:45:44 UTC 2014


Hi Mark,

I think in the normal case, the memory is freed by the calling
function. It looks like the other cases aren't consistent though.

Michael

On 21/03/14 14:04, Mark Sheppard wrote:
> Hi Chris,
>    thanks for the review ... yes, the question is intentional.
> the freeing of netaddrP is inconsistent on the NULL returns, so I just 
> flagged it to
> solicit opinion from those more familiar with this code, to
> see if netaddrP should be freed prior to return ... L555 is another 
> case as you have pointed out.
> netaddrP is obtained from the ifs in parameter.
> Interestingly, a "normal" return doesn't seem to free netaddrP.
> so its a minor conundrum
>
> regards
> Mark
>
>
> On 21/03/2014 13:43, Chris Hegarty wrote:
>> This looks ok to me Mark.
>>
>> You have added a question/comment on L514. Is this intentional?
>>
>> L555. Not directly related to your changes, but should netaddrP be 
>> freed there before returning NULL?
>>
>> -Chris.
>>
>> On 14/03/14 19:04, Mark Sheppard wrote:
>>> Hi
>>>
>>>    Please oblige and review the following changes
>>> http://cr.openjdk.java.net/~msheppar/8035631/webrev/
>>>
>>> which address the issues raised in
>>> https://bugs.openjdk.java.net/browse/JDK-8035631
>>>
>>> Summary:
>>> added CHECK_NULL_RETURN after JNI calls
>>>
>>> regards
>>> Mark
>>>
>



More information about the net-dev mailing list