Re: [PATCH 1/4] btrfs-progs: Fix infinite loop of btrfs subvolumn sync

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Aug 26, 2015 at 10:03:36PM +0800, Zhao Lei wrote:
> We can trigger the bug by following operation:
>   (no wait between commands 3~5)
>   btrfs subvolume create /mnt/btrfs/mysubvol
>   btrfs subvolume snapshot /mnt/btrfs/mysubvol /mnt/btrfs/mysubvol_snap
>   btrfs subvolume delete /mnt/btrfs/mysubvol_snap
>   btrfs subvolume delete /mnt/btrfs/mysubvol
>   btrfs subvolume sync /mnt/btrfs
> The last command will not exit.
> 
> Reason:
>   List of "deleted subvolumes" are not currectly set.
> 
>   It caused by a typo of value assign, in detail:
>   *ids[idx] = sh->offset;
>   should be:
>   (*ids)[idx] = sh->offset;
>   So only first element is set to right memory address.
> 
>   If there are multiple "deleted subvolumes", program will
>   keep wait.
> 
> Above typo also caused some segment fault in my test.
> 
> This patch fixed above bug.
> 
> Signed-off-by: Zhao Lei <zhaolei@xxxxxxxxxxxxxx>

Applied, thanks.
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux