From 1b5d9b2386e6195f58ff9eb7993311505d8e9b90 Mon Sep 17 00:00:00 2001 From: Patrick Valentin Date: Fri, 24 May 2013 14:14:20 +0200 Subject: [PATCH] LU-3383 utils: typo in lfs print_quota() function In the print_quota() function of 'lfs quota' command, the following sequence is to determine if the inode grace time is expired: if (dqb->dqb_btime > now) { iover = 2; The test must be done on dqb_itime (inode time), instead of dqb_btime (data time). Signed-off-by: Patrick Valentin Change-Id: I1aa9dc9c25ba219ea2272165d21895220a9ef9a7 Reviewed-on: http://review.whamcloud.com/6444 Reviewed-by: Fan Yong Reviewed-by: Niu Yawei Tested-by: Hudson Tested-by: Maloo Reviewed-by: Oleg Drokin --- lustre/utils/lfs.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lustre/utils/lfs.c b/lustre/utils/lfs.c index 5b2e45e..66e3728 100644 --- a/lustre/utils/lfs.c +++ b/lustre/utils/lfs.c @@ -2484,11 +2484,11 @@ static void print_quota(char *mnt, struct if_quotactl *qctl, int type, int rc) dqb->dqb_curinodes >= dqb->dqb_ihardlimit) { iover = 1; } else if (dqb->dqb_isoftlimit && dqb->dqb_itime) { - if (dqb->dqb_btime > now) { - iover = 2; - } else { - iover = 3; - } + if (dqb->dqb_itime > now) { + iover = 2; + } else { + iover = 3; + } } #if 0 /* XXX: always print quotas even when no usages */ -- 1.8.3.1