Date: Thu, 15 Mar 2007 21:49:12 GMT From: John Baldwin <jhb@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 115947 for review Message-ID: <200703152149.l2FLnC2a078904@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=115947 Change 115947 by jhb@jhb_mutex on 2007/03/15 21:48:56 Don't leak socket fd's if we get a fault trying to copyout the values. Need to write a test case before this goes into CVS. Affected files ... .. //depot/projects/smpng/sys/kern/uipc_syscalls.c#99 edit Differences ... ==== //depot/projects/smpng/sys/kern/uipc_syscalls.c#99 (text+ko) ==== @@ -665,6 +665,8 @@ fp2->f_type = DTYPE_SOCKET; FILE_UNLOCK(fp2); error = copyout(sv, uap->rsv, 2 * sizeof (int)); + if (error) + goto free4; fdrop(fp1, td); fdrop(fp2, td); goto done2;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200703152149.l2FLnC2a078904>