RAMFS: ramfs_close_attr needs a write-lock.

This commit is contained in:
Augustin Cavalier 2024-11-22 21:30:18 -05:00
parent bab3f64413
commit ce5375c0bf

View File

@ -1648,7 +1648,7 @@ ramfs_close_attr(fs_volume* _volume, fs_vnode* _node, void* _cookie)
Volume* volume = (Volume*)_volume->private_volume; Volume* volume = (Volume*)_volume->private_volume;
Node* node = (Node*)_node->private_node; Node* node = (Node*)_node->private_node;
VolumeReadLocker locker(volume); VolumeWriteLocker locker(volume);
if (!locker.IsLocked()) if (!locker.IsLocked())
RETURN_ERROR(B_ERROR); RETURN_ERROR(B_ERROR);