--- src/sys/kern/uipc_syscalls.c 2004/10/22 13:42:14 1.43 +++ src/sys/kern/uipc_syscalls.c 2004/11/12 00:09:24 1.44 @@ -109,7 +109,6 @@ kern_socket(int domain, int type, int pr error = falloc(p, &fp, &fd); if (error) return (error); - fhold(fp); error = socreate(domain, &so, type, protocol, td); if (error) { if (fdp->fd_ofiles[fd] == fp) { @@ -271,7 +270,6 @@ kern_accept(int s, struct sockaddr **nam fdrop(lfp, td); return (error); } - fhold(nfp); *res = fd; head = (struct socket *)lfp->f_data; @@ -355,7 +353,7 @@ done: /* * Release explicitly held references before returning. */ - if (nfp != NULL) + if (nfp) fdrop(nfp, td); fdrop(lfp, td); return (error); @@ -501,13 +499,11 @@ kern_socketpair(int domain, int type, in error = falloc(p, &fp1, &fd); if (error) goto free2; - fhold(fp1); sv[0] = fd; fp1->f_data = (caddr_t)so1; error = falloc(p, &fp2, &fd); if (error) goto free3; - fhold(fp2); fp2->f_data = (caddr_t)so2; sv[1] = fd; error = soconnect2(so1, so2);