]> git.proxmox.com Git - mirror_zfs.git/commit - module/zfs/zfs_ioctl.c
Relax restriction on zfs_ioc_next_obj() iteration
authorAntonio Russo <antonio.e.russo@gmail.com>
Wed, 13 May 2015 14:16:42 +0000 (07:16 -0700)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Thu, 14 May 2015 18:16:08 +0000 (11:16 -0700)
commit7290cd3c4ed19fb3f75b8133db2e36afcdd24beb
treec631490a03c966577b95bc55e92271138053e8e7
parentfd0fd6467bb8638b1496ad5a63b74f19fbd607df
Relax restriction on zfs_ioc_next_obj() iteration

Per the documentation for dnode_next_offset in dnode.c, the "txg"
parameter specifies a lower bound on which transaction the dnode can
be found in. We are interested in all dnodes that are removed between
the first and last transaction in the snapshot. It doesn't need to be
created in that snapshot to correspond to a removed file.

In fact, the behavior of zfs diff in the test case exactly matches
this: the transaction that created the data that was deleted in snapshot
"2" was produced before, in snapshot "1", definitely predating the first
transaction in snapshot "2".

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tim Chase <Tim Chase <tim@onlight.com>
Closes #2081
module/zfs/zfs_ioctl.c