[PATCH v1 2/4] tests/quotactl-xfs.c: fix disorder of PRINT_FIELD_U invocations

Dmitry V. Levin ldv at altlinux.org
Tue Jul 10 11:40:25 UTC 2018


On Mon, Jul 09, 2018 at 12:11:30AM +0800, Zhibin Li wrote:
> ---
>  tests/quotactl-xfs.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/quotactl-xfs.c b/tests/quotactl-xfs.c
> index fab451e2..036b61d2 100644
> --- a/tests/quotactl-xfs.c
> +++ b/tests/quotactl-xfs.c
> @@ -142,14 +142,14 @@ print_xquota_stat(int rc, void *ptr, void *arg)
>  # if VERBOSE
>  	printf(", qs_flags=");
>  	printflags(xfs_quota_flags, qs->qs_flags, "XFS_QUOTA_???");
> +	PRINT_FIELD_U(", ", *qs, qs_incoredqs);
>  	PRINT_FIELD_U(", qs_uquota={", qs->qs_uquota, qfs_ino);
>  	PRINT_FIELD_U(", ", qs->qs_uquota, qfs_nblks);
>  	PRINT_FIELD_U(", ", qs->qs_uquota, qfs_nextents);
>  	PRINT_FIELD_U("}, qs_gquota={", qs->qs_gquota, qfs_ino);
>  	PRINT_FIELD_U(", ", qs->qs_gquota, qfs_nblks);
>  	PRINT_FIELD_U(", ", qs->qs_gquota, qfs_nextents);
> -	PRINT_FIELD_U("}, ", *qs, qs_incoredqs);
> -	PRINT_FIELD_D(", ", *qs, qs_btimelimit);
> +	PRINT_FIELD_D("}, ", *qs, qs_btimelimit);
>  	PRINT_FIELD_D(", ", *qs, qs_itimelimit);
>  	PRINT_FIELD_D(", ", *qs, qs_rtbtimelimit);
>  	PRINT_FIELD_U(", ", *qs, qs_bwarnlimit);

The original order is correct, you must be confusing struct fs_quota_stat
with struct fs_quota_statv where qs_incoredqs precedes qs_uquota.


-- 
ldv
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20180710/9c66023f/attachment.bin>


More information about the Strace-devel mailing list