aboutsummaryrefslogtreecommitdiff
path: root/sys/i386
diff options
context:
space:
mode:
authorJohn Baldwin <jhb@FreeBSD.org>2018-01-17 22:36:58 +0000
committerJohn Baldwin <jhb@FreeBSD.org>2018-01-17 22:36:58 +0000
commitb1288166e0f73ddc7f5b8de210db62e987dda609 (patch)
tree05554e6a69b2f81e0dc24cf191091d4e81ff45ec /sys/i386
parent19a63eb534a17b9a61626315b58cf557b6913d02 (diff)
downloadsrc-b1288166e0f73ddc7f5b8de210db62e987dda609.tar.gz
src-b1288166e0f73ddc7f5b8de210db62e987dda609.zip
Use long for the last argument to VOP_PATHCONF rather than a register_t.
pathconf(2) and fpathconf(2) both return a long. The kern_[f]pathconf() functions now accept a pointer to a long value rather than modifying td_retval directly. Instead, the system calls explicitly store the returned long value in td_retval[0]. Requested by: bde Reviewed by: kib Sponsored by: Chelsio Communications
Notes
Notes: svn path=/head/; revision=328099
Diffstat (limited to 'sys/i386')
-rw-r--r--sys/i386/ibcs2/ibcs2_misc.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sys/i386/ibcs2/ibcs2_misc.c b/sys/i386/ibcs2/ibcs2_misc.c
index c166d78a1486..ea7f133a0161 100644
--- a/sys/i386/ibcs2/ibcs2_misc.c
+++ b/sys/i386/ibcs2/ibcs2_misc.c
@@ -737,12 +737,16 @@ int
ibcs2_pathconf(struct thread *td, struct ibcs2_pathconf_args *uap)
{
char *path;
+ long value;
int error;
CHECKALTEXIST(td, uap->path, &path);
uap->name++; /* iBCS2 _PC_* defines are offset by one */
- error = kern_pathconf(td, path, UIO_SYSSPACE, uap->name, FOLLOW);
+ error = kern_pathconf(td, path, UIO_SYSSPACE, uap->name, FOLLOW,
+ &value);
free(path, M_TEMP);
+ if (error == 0)
+ td->td_retval[0] = value;
return (error);
}