mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-21 15:45:02 +00:00
o Rearrange and remove incorrect comments.
Requested by: bde
This commit is contained in:
parent
c7f17eb45c
commit
e680b88a3d
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=159109
@ -509,8 +509,9 @@ ufs_setattr(ap)
|
||||
}
|
||||
if (vap->va_size != VNOVAL) {
|
||||
/*
|
||||
* XXX most of this checking should be in callers instead
|
||||
* of in N filesystems. The VDIR check mostly already is.
|
||||
* XXX most of the following special cases should be in
|
||||
* callers instead of in N filesystems. The VDIR check
|
||||
* mostly already is.
|
||||
*/
|
||||
switch (vp->v_type) {
|
||||
case VDIR:
|
||||
@ -521,12 +522,6 @@ ufs_setattr(ap)
|
||||
* Truncation should have an effect in these cases.
|
||||
* Disallow it if the filesystem is read-only or
|
||||
* the file is being snapshotted.
|
||||
*
|
||||
* XXX unfortunately the snapshot check can't be
|
||||
* more global since we want to check other things
|
||||
* first so as to return better error codes. But
|
||||
* we miss several cases (file flags and ownership
|
||||
* changes at least) by not doing a central check.
|
||||
*/
|
||||
if (vp->v_mount->mnt_flag & MNT_RDONLY)
|
||||
return (EROFS);
|
||||
|
Loading…
Reference in New Issue
Block a user