A followup to r320453, correct removal of the blocks from UFS snapshots.

Tested by:	pho
PR:    220693
Sponsored by:	The FreeBSD Foundation
This commit is contained in:
Konstantin Belousov 2017-07-16 07:11:29 +00:00
parent 8695518c44
commit 51a6a15f8c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=321040

View File

@ -2603,7 +2603,8 @@ ffs_getcg(fs, devvp, cg, bpp, cgpp)
*bpp = NULL;
*cgpp = NULL;
error = bread(devvp, fsbtodb(fs, cgtod(fs, cg)),
error = bread(devvp, devvp->v_type == VREG ?
fragstoblks(fs, cgtod(fs, cg)) : fsbtodb(fs, cgtod(fs, cg)),
(int)fs->fs_cgsize, NOCRED, &bp);
if (error != 0)
return (error);