]> git.proxmox.com Git - mirror_zfs.git/commit - include/sys/zfs_znode.h
Fix zil_commit() NULL dereference
authorBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 15 Jul 2014 20:29:57 +0000 (13:29 -0700)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Thu, 17 Jul 2014 22:15:07 +0000 (15:15 -0700)
commit1e8db7710220332808920a582e5794d6fc37b109
tree5480855f5bc841e32703bc7cf4f0835b212f3077
parenta5778ea2427bd340e3b4f697d9b6e1452bd71909
Fix zil_commit() NULL dereference

Update the current code to ensure inodes are never dirtied if they are
part of a read-only file system or snapshot.  If they do somehow get
dirtied an attempt will make made to write them to disk.  In the case
of snapshots, which don't have a ZIL, this will result in a NULL
dereference in zil_commit().

Signed-off-by: Richard Yao <ryao@gentoo.org>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #2405
include/sys/zfs_znode.h
module/zfs/zfs_vnops.c
module/zfs/zfs_znode.c
module/zfs/zpl_file.c
module/zfs/zpl_xattr.c