Re: [PATCH V2] generic/395: test GETNEXTQUOTA near INT_MAX

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



On Wed, Dec 21, 2016 at 07:11:21PM -0600, Eric Sandeen wrote:
> XFS kernel code had a bug where GETNEXTQUOTA-type
> quotactls requesting an ID near UINT_MAX could overflow
> and return 0 as the "next" active ID.
> 
> This test checks that by creating an active quota near
> UINT_MAX, then asking for the next one after it.
> 
> The proper answer is ENOENT, but if we wrap we'll return
> ID 0.
> 
> This also changes test-nextquota.c so that it checks
> both GETNEXTQUOTA and XGETNEXTQUOTA even if one fails;
> it stores the failure conditions and returns 1 if either
> of them fails.
> 
> Signed-off-by: Eric Sandeen <sandeen@xxxxxxxxxx>
> ---
> 
> V2: cleanups from Eryu's review.
> 
> Eryu - I need to send a _require_getnextquota patch, and some
> other cleanups to 244, similar to your review of this test
> (I copied this test from 244).
> 
> I'll do that in reply to this patch, hopfully tonight, yet.

Thanks, Eric!

> +# remount just for kicks, make sure we get it off disk
> +_scratch_unmount
> +_qmount
> +quotaon $SCRATCH_MNT 2>/dev/null

I removed this quotaon too and merged.

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



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

  Powered by Linux