diff options
author | Alfred Perlstein <alfred@FreeBSD.org> | 2002-12-14 01:56:26 +0000 |
---|---|---|
committer | Alfred Perlstein <alfred@FreeBSD.org> | 2002-12-14 01:56:26 +0000 |
commit | d1e405c5ce42fef2970847769c8017b952b5d318 (patch) | |
tree | f2f1c63d7a3acfeb3493534ac55908632c5769ee /sys/compat/svr4/svr4_filio.c | |
parent | 0db138a6b0df9d7ae412c29a0d3ed4fa094d01ed (diff) |
SCARGS removal take II.
Notes
Notes:
svn path=/head/; revision=107849
Diffstat (limited to 'sys/compat/svr4/svr4_filio.c')
-rw-r--r-- | sys/compat/svr4/svr4_filio.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/sys/compat/svr4/svr4_filio.c b/sys/compat/svr4/svr4_filio.c index c2bad1d41b14..f4b0950ec347 100644 --- a/sys/compat/svr4/svr4_filio.c +++ b/sys/compat/svr4/svr4_filio.c @@ -63,26 +63,26 @@ svr4_sys_poll(td, uap) int idx = 0, cerr; u_long siz; - SCARG(&pa, fds) = SCARG(uap, fds); - SCARG(&pa, nfds) = SCARG(uap, nfds); - SCARG(&pa, timeout) = SCARG(uap, timeout); + pa.fds = uap->fds; + pa.nfds = uap->nfds; + pa.timeout = uap->timeout; - siz = SCARG(uap, nfds) * sizeof(struct pollfd); + siz = uap->nfds * sizeof(struct pollfd); pfd = (struct pollfd *)malloc(siz, M_TEMP, M_WAITOK); error = poll(td, (struct poll_args *)uap); - if ((cerr = copyin(SCARG(uap, fds), pfd, siz)) != 0) { + if ((cerr = copyin(uap->fds, pfd, siz)) != 0) { error = cerr; goto done; } - for (idx = 0; idx < SCARG(uap, nfds); idx++) { + for (idx = 0; idx < uap->nfds; idx++) { /* POLLWRNORM already equals POLLOUT, so we don't worry about that */ if (pfd[idx].revents & (POLLOUT | POLLWRNORM | POLLWRBAND)) pfd[idx].revents |= (POLLOUT | POLLWRNORM | POLLWRBAND); } - if ((cerr = copyout(pfd, SCARG(uap, fds), siz)) != 0) { + if ((cerr = copyout(pfd, uap->fds, siz)) != 0) { error = cerr; goto done; /* yeah, I know it's the next line, but this way I won't forget to update it if I add more code */ @@ -105,9 +105,9 @@ svr4_sys_read(td, uap) sigset_t sigmask; int rv; - SCARG(&ra, fd) = SCARG(uap, fd); - SCARG(&ra, buf) = SCARG(uap, buf); - SCARG(&ra, nbyte) = SCARG(uap, nbyte); + ra.fd = uap->fd; + ra.buf = uap->buf; + ra.nbyte = uap->nbyte; if (fget(td, uap->fd, &fp) != 0) { DPRINTF(("Something fishy with the user-supplied file descriptor...\n")); @@ -116,9 +116,9 @@ svr4_sys_read(td, uap) if (fp->f_type == DTYPE_SOCKET) { so = (struct socket *)fp->f_data; - DPRINTF(("fd %d is a socket\n", SCARG(uap, fd))); + DPRINTF(("fd %d is a socket\n", uap->fd)); if (so->so_state & SS_ASYNC) { - DPRINTF(("fd %d is an ASYNC socket!\n", SCARG(uap, fd))); + DPRINTF(("fd %d is an ASYNC socket!\n", uap->fd)); } DPRINTF(("Here are its flags: 0x%x\n", so->so_state)); #if defined(GROTTY_READ_HACK) @@ -130,7 +130,7 @@ svr4_sys_read(td, uap) rv = read(td, &ra); DPRINTF(("svr4_read(%d, 0x%0x, %d) = %d\n", - SCARG(uap, fd), SCARG(uap, buf), SCARG(uap, nbyte), rv)); + uap->fd, uap->buf, uap->nbyte, rv)); if (rv == EAGAIN) { DPRINTF(("sigmask = 0x%x\n", td->td_proc->p_sigmask)); DPRINTF(("sigignore = 0x%x\n", td->td_proc->p_sigignore)); @@ -159,14 +159,14 @@ svr4_sys_write(td, uap) struct file *fp; int rv; - SCARG(&wa, fd) = SCARG(uap, fd); - SCARG(&wa, buf) = SCARG(uap, buf); - SCARG(&wa, nbyte) = SCARG(uap, nbyte); + wa.fd = uap->fd; + wa.buf = uap->buf; + wa.nbyte = uap->nbyte; rv = write(td, &wa); DPRINTF(("svr4_write(%d, 0x%0x, %d) = %d\n", - SCARG(uap, fd), SCARG(uap, buf), SCARG(uap, nbyte), rv)); + uap->fd, uap->buf, uap->nbyte, rv)); return(rv); } |