summaryrefslogtreecommitdiffstats
path: root/sys/compat
diff options
context:
space:
mode:
authorpjd <pjd@FreeBSD.org>2005-05-22 22:30:31 +0000
committerpjd <pjd@FreeBSD.org>2005-05-22 22:30:31 +0000
commitabf228987206d99eefbf00bd06d5097259a4604a (patch)
tree6484e8ac197567235efe003ad1afae18e56f7d49 /sys/compat
parentcbc50a66378df7c09d244d7f2d2ba61d1c8c4908 (diff)
downloadFreeBSD-src-abf228987206d99eefbf00bd06d5097259a4604a.zip
FreeBSD-src-abf228987206d99eefbf00bd06d5097259a4604a.tar.gz
The code is under '#ifdef not_that_way', but anyway:
- Add missing prison_check_mount() check.
Diffstat (limited to 'sys/compat')
-rw-r--r--sys/compat/linux/linux_stats.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/compat/linux/linux_stats.c b/sys/compat/linux/linux_stats.c
index f446ec6..cf783aa 100644
--- a/sys/compat/linux/linux_stats.c
+++ b/sys/compat/linux/linux_stats.c
@@ -36,6 +36,7 @@ __FBSDID("$FreeBSD$");
#include <sys/file.h>
#include <sys/filedesc.h>
#include <sys/proc.h>
+#include <sys/jail.h>
#include <sys/mac.h>
#include <sys/malloc.h>
#include <sys/mount.h>
@@ -331,6 +332,8 @@ linux_ustat(struct thread *td, struct linux_ustat_args *args)
if (dev != NULL && vfinddev(dev, &vp)) {
if (vp->v_mount == NULL)
return (EINVAL);
+ if (!prison_check_mount(td->td_ucred, vp->v_mount))
+ return (EINVAL);
#ifdef MAC
error = mac_check_mount_stat(td->td_ucred, vp->v_mount);
if (error)
OpenPOWER on IntegriCloud