]> Zhao Yanbai Git Server - minix.git/commitdiff
Mark filp as in use on fd dup'ing
authorThomas Veerman <thomas@minix3.org>
Fri, 16 Dec 2011 08:43:01 +0000 (08:43 +0000)
committerThomas Veerman <thomas@minix3.org>
Wed, 21 Dec 2011 10:45:29 +0000 (10:45 +0000)
servers/avfs/misc.c

index f05352619774feba5bc2ab4b4a811dded74fc9d1..2cb7f3b8bdb2d3c699eb448bb36a0881e2e8858b 100644 (file)
@@ -168,6 +168,7 @@ PUBLIC int do_fcntl()
        else if ((r = get_fd(m_in.addr, 0, &new_fd, NULL)) == OK) {
                f->filp_count++;
                fp->fp_filp[new_fd] = f;
+               FD_SET(new_fd, &fp->fp_filp_inuse);
                r = new_fd;
        }
        break;