diff options
author | jhb <jhb@FreeBSD.org> | 2006-07-08 20:03:39 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2006-07-08 20:03:39 +0000 |
commit | e09e5b52dbb8914136f6708a8042007a16277dde (patch) | |
tree | 2f42b6b122203b412debeb7c4d7a7de8a551de99 /sys/compat/linux/linux_socket.c | |
parent | df27227bab23aaf42551e2e2ea6f0955e253f135 (diff) | |
download | FreeBSD-src-e09e5b52dbb8914136f6708a8042007a16277dde.zip FreeBSD-src-e09e5b52dbb8914136f6708a8042007a16277dde.tar.gz |
Add a kern_close() so that the ABIs can close a file descriptor w/o having
to populate a close_args struct and change some of the places that do.
Diffstat (limited to 'sys/compat/linux/linux_socket.c')
-rw-r--r-- | sys/compat/linux/linux_socket.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/sys/compat/linux/linux_socket.c b/sys/compat/linux/linux_socket.c index dfe2e50..8b164fa 100644 --- a/sys/compat/linux/linux_socket.c +++ b/sys/compat/linux/linux_socket.c @@ -705,9 +705,6 @@ linux_accept(struct thread *td, struct linux_accept_args *args) struct sockaddr * __restrict name; socklen_t * __restrict anamelen; } */ bsd_args; - struct close_args /* { - int fd; - } */ c_args; int error, fd; if ((error = copyin(args, &linux_args, sizeof(linux_args)))) @@ -724,8 +721,7 @@ linux_accept(struct thread *td, struct linux_accept_args *args) if (linux_args.addr) { error = linux_sa_put(PTRIN(linux_args.addr)); if (error) { - c_args.fd = td->td_retval[0]; - (void)close(td, &c_args); + (void)kern_close(td, td->td_retval[0]); return (error); } } |