RFR [8055421]: Unknown error in UnixNativeDispatcher

Florian Weimer fweimer at redhat.com
Wed Aug 20 09:02:02 UTC 2014


On 08/20/2014 10:24 AM, Ivan Gerasimov wrote:
> Thanks Florian!
>
> On 19.08.2014 22:56, Florian Weimer wrote:
>> On 08/19/2014 06:17 PM, Ivan Gerasimov wrote:
>>
>>> A bug is observed due to erroneous use of errno.
>>> Would you please review the simple fix?
>>>
>>> BUGURL: https://bugs.openjdk.java.net/browse/JDK-8055421
>>> WEBREV: http://cr.openjdk.java.net/~igerasim/8055421/0/webrev/
>>
>> The change is fine, but the fact that this is visible at all is
>> surprising.  What is setting errno to -1?
>>
> The problem here is that errno is set to something != -1, and, as a
> consequence, an exception isn't thrown upon the failure.

On Linux, as indicated in the bug report?  closedir cannot really fail 
there.

That's why I think the analysis in the bug is suspect.

-- 
Florian Weimer / Red Hat Product Security


More information about the nio-dev mailing list