diff options
author | tegge <tegge@FreeBSD.org> | 2006-09-26 04:19:11 +0000 |
---|---|---|
committer | tegge <tegge@FreeBSD.org> | 2006-09-26 04:19:11 +0000 |
commit | 34ea634be74b46f8326b06761eb1e444957160ad (patch) | |
tree | e9bab20e118499ff1c4577564930a58766b7bc92 /sys | |
parent | a802c35eb4beea451e9fea598128fb06b96e1aae (diff) | |
download | FreeBSD-src-34ea634be74b46f8326b06761eb1e444957160ad.zip FreeBSD-src-34ea634be74b46f8326b06761eb1e444957160ad.tar.gz |
Don't restore MNT_QUOTA bit in mnt_flag after snapshot creation,
closing a race between nmount() and quotactl().
Diffstat (limited to 'sys')
-rw-r--r-- | sys/ufs/ffs/ffs_snapshot.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/ufs/ffs/ffs_snapshot.c b/sys/ufs/ffs/ffs_snapshot.c index f23f098..473dbfd 100644 --- a/sys/ufs/ffs/ffs_snapshot.c +++ b/sys/ufs/ffs/ffs_snapshot.c @@ -832,7 +832,7 @@ out: } UFS_UNLOCK(ump); MNT_ILOCK(mp); - mp->mnt_flag = flag; + mp->mnt_flag = (mp->mnt_flag & MNT_QUOTA) | (flag & ~MNT_QUOTA); MNT_IUNLOCK(mp); if (error) (void) ffs_truncate(vp, (off_t)0, 0, NOCRED, td); |