diff options
author | Jan Kara <jack@suse.cz> | 2015-06-24 12:07:02 -0400 |
---|---|---|
committer | Jan Kara <jack@suse.com> | 2015-07-23 14:59:10 -0400 |
commit | 6184fc0b8dd76c6aedc7a26e93254993e14e52de (patch) | |
tree | 8d6946f82158c8de4ab67115eff3a02c064b343d /fs/ocfs2/quota_local.c | |
parent | d725e66c06ab440032f49ef17e960896d0ec6d49 (diff) |
quota: Propagate error from ->acquire_dquot()
Currently when some error happened in ->acquire_dquot(), dqget() just
returned NULL. That was indistinguishable from a case when e.g. someone
run quotaoff and so was generally silently ignored. However
->acquire_dquot() can fail because of ENOSPC or EIO in which case user
should better know. So propagate error up from ->acquire_dquot properly.
Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/ocfs2/quota_local.c')
-rw-r--r-- | fs/ocfs2/quota_local.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/ocfs2/quota_local.c b/fs/ocfs2/quota_local.c index 3d0b63d34225..bb07004df72a 100644 --- a/fs/ocfs2/quota_local.c +++ b/fs/ocfs2/quota_local.c | |||
@@ -499,8 +499,8 @@ static int ocfs2_recover_local_quota_file(struct inode *lqinode, | |||
499 | dquot = dqget(sb, | 499 | dquot = dqget(sb, |
500 | make_kqid(&init_user_ns, type, | 500 | make_kqid(&init_user_ns, type, |
501 | le64_to_cpu(dqblk->dqb_id))); | 501 | le64_to_cpu(dqblk->dqb_id))); |
502 | if (!dquot) { | 502 | if (IS_ERR(dquot)) { |
503 | status = -EIO; | 503 | status = PTR_ERR(dquot); |
504 | mlog(ML_ERROR, "Failed to get quota structure " | 504 | mlog(ML_ERROR, "Failed to get quota structure " |
505 | "for id %u, type %d. Cannot finish quota " | 505 | "for id %u, type %d. Cannot finish quota " |
506 | "file recovery.\n", | 506 | "file recovery.\n", |