ttoo big fd - plan9port - [fork] Plan 9 from user space
 (HTM) git clone git://src.adamsgaard.dk/plan9port
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit a0d2173ce4c9b9d530352f3890898ad3af19ae06
 (DIR) parent 3300f9cd89202e417dee8f1799e88f955d75ac89
 (HTM) Author: rsc <devnull@localhost>
       Date:   Sun, 16 Jan 2005 17:37:11 +0000
       
       ttoo big fd
       
       Diffstat:
         M src/libthread/daemonize.c           |       7 ++++---
       
       1 file changed, 4 insertions(+), 3 deletions(-)
       ---
 (DIR) diff --git a/src/libthread/daemonize.c b/src/libthread/daemonize.c
       t@@ -100,12 +100,13 @@ _threadsetupdaemonize(void)
                        sysfatal("passer pipe: %r");
        
                /* hide these somewhere they won't cause harm */
       -        if(dup(p[0], 98) < 0 || dup(p[1], 99) < 0)
       +        /* can't go too high: NetBSD max is 64, for example */
       +        if(dup(p[0], 28) < 0 || dup(p[1], 29) < 0)
                        sysfatal("passer pipe dup: %r");
                close(p[0]);
                close(p[1]);
       -        p[0] = 98;
       -        p[1] = 99;
       +        p[0] = 28;
       +        p[1] = 29;
        
                /* close on exec */
                if(fcntl(p[0], F_SETFD, 1) < 0 || fcntl(p[1], F_SETFD, 1) < 0)