All of lore.kernel.org
 help / color / mirror / Atom feed
From: Norton.Zhu <norton.zhu@huawei.com>
To: ocfs2-devel@oss.oracle.com
Subject: [Ocfs2-devel] [PATCH] ocfs2_direct_IO_write misses ocfs2_is_overwrite error code
Date: Mon, 7 Sep 2015 10:11:56 +0800	[thread overview]
Message-ID: <55ECF26C.4000100@huawei.com> (raw)

If ocfs2_is_overwrite failed, ocfs2_direct_IO_write mays till return success to the caller.

Signed-off-by: Norton.Zhu <norton.zhu@huawei.com>
---
 aops.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/aops.c b/aops.c
index 0f5fd9d..4107279 100644
--- a/aops.c
+++ b/aops.c
@@ -847,6 +847,7 @@ static ssize_t ocfs2_direct_IO_write(struct kiocb *iocb,
 		is_overwrite = ocfs2_is_overwrite(osb, inode, offset);
 		if (is_overwrite < 0) {
 			mlog_errno(is_overwrite);
+			ret = is_overwrite;
 			ocfs2_inode_unlock(inode, 1);
 			goto clean_orphan;
 		}
-- 
1.8.4.3

             reply	other threads:[~2015-09-07  2:11 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-07  2:11 Norton.Zhu [this message]
2015-09-11 21:20 ` [Ocfs2-devel] [PATCH] ocfs2_direct_IO_write misses ocfs2_is_overwrite error code Andrew Morton

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=55ECF26C.4000100@huawei.com \
    --to=norton.zhu@huawei.com \
    --cc=ocfs2-devel@oss.oracle.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.