summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2002-10-02 09:11:18 +0000
committerphk <phk@FreeBSD.org>2002-10-02 09:11:18 +0000
commitf98c8d3a060b006e04ae9474a17d395ab7df7180 (patch)
tree7355f6b7fbb26e03618d927edc46e51e7eeb69b5
parent76d8452fbf18bce17a23e44b82b63c40eae1a607 (diff)
downloadFreeBSD-src-f98c8d3a060b006e04ae9474a17d395ab7df7180.zip
FreeBSD-src-f98c8d3a060b006e04ae9474a17d395ab7df7180.tar.gz
Mark two places where an unsigned number is checked "if (foo < 0)" with
an XXX comment. Somebody[TM] should look at this in some detail. Spotted by: FlexeLint
-rw-r--r--sys/ufs/ufs/ufs_quota.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/ufs/ufs/ufs_quota.c b/sys/ufs/ufs/ufs_quota.c
index 6831690..2582412 100644
--- a/sys/ufs/ufs/ufs_quota.c
+++ b/sys/ufs/ufs/ufs_quota.c
@@ -254,6 +254,7 @@ chkiq(ip, change, cred, flags)
#endif
if (change == 0)
return (0);
+ /* XXX: change is unsigned */
if (change < 0) {
for (i = 0; i < MAXQUOTAS; i++) {
if ((dq = ip->i_dquot[i]) == NODQUOT)
@@ -263,6 +264,7 @@ chkiq(ip, change, cred, flags)
(void) tsleep((caddr_t)dq, PINOD+1, "chkiq1", 0);
}
ncurinodes = dq->dq_curinodes + change;
+ /* XXX: ncurinodes is unsigned */
if (ncurinodes >= 0)
dq->dq_curinodes = ncurinodes;
else
OpenPOWER on IntegriCloud