Whamcloud - gitweb
LU-882 quota: Quota code compares unsigned < 0
[fs/lustre-release.git] / lustre / quota / quota_context.c
index 05179ec..f1be4f8 100644 (file)
@@ -325,7 +325,7 @@ check_cur_qunit(struct obd_device *obd,
         limit_org = limit;
         /* when a releasing quota req is sent, before it returned
            limit is assigned a small value. limit will overflow */
-        if (limit + record < 0)
+        if (record < 0)
                 usage -= record;
         else
                 limit += record;