NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: lib/45148: dup2(3) and dup3(3) should support EINVAL



The following reply was made to PR lib/45148; it has been noted by GNATS.

From: Martin Husemann <martin%duskware.de@localhost>
To: gnats-bugs%NetBSD.org@localhost, netbsd-bugs%NetBSD.org@localhost,
        Christos Zoulas <christos%NetBSD.org@localhost>
Cc: 
Subject: Re: lib/45148: dup2(3) and dup3(3) should support EINVAL
Date: Sat, 16 Jul 2011 12:15:27 +0200

 On Sat, Jul 16, 2011 at 02:35:28AM +0300, Jukka Ruohonen wrote:
 > Can martin@ or christos@ comment about the avove? Surely it must be
 > impossible to fail with EMFAIL if these always close a descriptor...
 
 dup() can fail with EMFILE, obviously. I don't think dup2 or dup3 can
 fail this way, as we guarantee atomicity by keeping filedescriptors
 locked over the whole operation.
 
 Martin
 


Home | Main Index | Thread Index | Old Index