fix fd bug
authorneilbrown <neilbrown>
Tue, 31 Aug 2004 06:37:20 +0000 (06:37 +0000)
committerneilbrown <neilbrown>
Tue, 31 Aug 2004 06:37:20 +0000 (06:37 +0000)
ChangeLog
utils/mountd/cache.c

index 0ebb3d8..34be741 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,9 @@
 2004-08-31 NeilBrown <neilb@cse.unsw.edu.au>
+       * utils/mountd/cache.c(cache_process_req): clear fd after
+       processing so as not to confused libc/sunrpc into thinking
+       it need to do something with that fd.
+       
+2004-08-31 NeilBrown <neilb@cse.unsw.edu.au>
 
        * debian/nfs-kernel-server.init(start,stop) mount the nfsd
        filesystem, if available, before starting nfs services, and 
index 3a16641..77029f4 100644 (file)
@@ -315,6 +315,7 @@ int cache_process_req(fd_set *readfds)
                    FD_ISSET(fileno(cachelist[i].f), readfds)) {
                        cnt++;
                        cachelist[i].cache_handle(cachelist[i].f);
+                       FD_CLR(fileno(cachelist[i].f), readfds);
                }
        }
        return cnt;