• Josef Bacik's avatar
    Btrfs: protect the pending_snapshots list with trans_lock · 8351583e
    Josef Bacik authored
    Currently there is nothing protecting the pending_snapshots list on the
    transaction.  We only hold the directory mutex that we are snapshotting and a
    read lock on the subvol_sem, so we could race with somebody else creating a
    snapshot in a different directory and end up with list corruption.  So protect
    this list with the trans_lock.  Thanks,
    Signed-off-by: default avatarJosef Bacik <josef@redhat.com>
    8351583e
ioctl.c 69.8 KB