summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorEric Sandeen <sandeen@redhat.com>2017-11-28 05:23:32 +0300
committerDarrick J. Wong <darrick.wong@oracle.com>2017-11-28 19:57:11 +0300
commiteda6bc27ccc852d34393739009486932f3ba70ae (patch)
treeb2806edb817b1be0542d2cbd7944b4b6cae3298d /fs
parentd41c6172bd4031979eab722c265a2e5764383c3c (diff)
downloadlinux-eda6bc27ccc852d34393739009486932f3ba70ae.tar.xz
xfs: fix uninitialized variable in xfs_scrub_quota
On the first pass through the while(1) loop, we get to xfs_scrub_should_terminate() which can test the uninitialized error variable. Fixes-coverity-id: 1423737 Fixes: c2fc338c ("xfs: scrub quota information") Signed-off-by: Eric Sandeen <sandeen@redhat.com> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/xfs/scrub/quota.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/xfs/scrub/quota.c b/fs/xfs/scrub/quota.c
index 8e58ba842946..613def9692a1 100644
--- a/fs/xfs/scrub/quota.c
+++ b/fs/xfs/scrub/quota.c
@@ -207,7 +207,7 @@ xfs_scrub_quota(
xfs_dqid_t id = 0;
uint dqtype;
int nimaps;
- int error;
+ int error = 0;
if (!XFS_IS_QUOTA_RUNNING(mp) || !XFS_IS_QUOTA_ON(mp))
return -ENOENT;