summaryrefslogtreecommitdiffstats
path: root/sys/gnu/ext2fs/ext2_readwrite.c
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2001-01-23 22:41:15 +0000
committerjhb <jhb@FreeBSD.org>2001-01-23 22:41:15 +0000
commit45daa2e3ce5127d3a90b289e0f3628ed66f7bce8 (patch)
tree4ff4ee72470aed31a91e531ffa7338143b8086bb /sys/gnu/ext2fs/ext2_readwrite.c
parent24fda4f13ec981051ae684c13423bcc48885891f (diff)
downloadFreeBSD-src-45daa2e3ce5127d3a90b289e0f3628ed66f7bce8.zip
FreeBSD-src-45daa2e3ce5127d3a90b289e0f3628ed66f7bce8.tar.gz
Proc locking, mostly protecting p_ucred while obtaining additional
references.
Diffstat (limited to 'sys/gnu/ext2fs/ext2_readwrite.c')
-rw-r--r--sys/gnu/ext2fs/ext2_readwrite.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/gnu/ext2fs/ext2_readwrite.c b/sys/gnu/ext2fs/ext2_readwrite.c
index 30a2f56..64065c3 100644
--- a/sys/gnu/ext2fs/ext2_readwrite.c
+++ b/sys/gnu/ext2fs/ext2_readwrite.c
@@ -217,6 +217,8 @@ WRITE(ap)
* file servers have no limits, I don't think it matters.
*/
p = uio->uio_procp;
+ /* For p_rlimit. */
+ mtx_assert(&Giant, MA_OWNED);
if (vp->v_type == VREG && p &&
uio->uio_offset + uio->uio_resid >
p->p_rlimit[RLIMIT_FSIZE].rlim_cur) {
OpenPOWER on IntegriCloud